youtarr use same network
This commit is contained in:
parent
c4d4ddecbc
commit
e3e009ffb2
1 changed files with 3 additions and 3 deletions
|
|
@ -17,9 +17,7 @@ in
|
||||||
virtualisation.oci-containers.containers = {
|
virtualisation.oci-containers.containers = {
|
||||||
"${name}" = {
|
"${name}" = {
|
||||||
image = "dialmaster/youtarr:latest";
|
image = "dialmaster/youtarr:latest";
|
||||||
ports = [
|
# No ports here - using shared network from DB container
|
||||||
"${toString port}:${toString port}"
|
|
||||||
];
|
|
||||||
volumes = [
|
volumes = [
|
||||||
"${hostDataDir}/config:/config"
|
"${hostDataDir}/config:/config"
|
||||||
"${mediaDir}:/downloads"
|
"${mediaDir}:/downloads"
|
||||||
|
|
@ -33,12 +31,14 @@ in
|
||||||
DB_PASSWORD = "123qweasd";
|
DB_PASSWORD = "123qweasd";
|
||||||
DB_NAME = name;
|
DB_NAME = name;
|
||||||
};
|
};
|
||||||
|
extraOptions = [ "--network=container:${name}-db" ];
|
||||||
dependsOn = [ "${name}-db" ];
|
dependsOn = [ "${name}-db" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"${name}-db" = {
|
"${name}-db" = {
|
||||||
image = "mariadb:10.3";
|
image = "mariadb:10.3";
|
||||||
ports = [
|
ports = [
|
||||||
|
"${toString port}:${toString port}"
|
||||||
"${toString dbPort}:${toString dbPort}"
|
"${toString dbPort}:${toString dbPort}"
|
||||||
];
|
];
|
||||||
volumes = [
|
volumes = [
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue