podman: assign hostsnames to containers
This commit is contained in:
parent
bef5faee5c
commit
9611570809
|
@ -42,9 +42,9 @@ in
|
||||||
# 10.88.1.1 -> Pihole
|
# 10.88.1.1 -> Pihole
|
||||||
imports = [
|
imports = [
|
||||||
./pihole.nix
|
./pihole.nix
|
||||||
|
./qbittorrent.nix
|
||||||
./redmage-demo.nix
|
./redmage-demo.nix
|
||||||
./redmage.nix
|
./redmage.nix
|
||||||
./qbittorrent.nix
|
|
||||||
./suwayomi.nix
|
./suwayomi.nix
|
||||||
./ytptube.nix
|
./ytptube.nix
|
||||||
];
|
];
|
||||||
|
|
|
@ -19,12 +19,13 @@ in
|
||||||
'';
|
'';
|
||||||
|
|
||||||
system.activationScripts."podman-${name}" = ''
|
system.activationScripts."podman-${name}" = ''
|
||||||
mkdir -p ${volume}/{config,downloads,progress,auto}
|
mkdir -p ${volume}/{config,downloads,progress,watch}
|
||||||
chown ${uid}:${gid} ${volume} ${volume}/{config,downloads,progress,auto}
|
chown ${uid}:${gid} ${volume} ${volume}/{config,downloads,progress,watch}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
virtualisation.oci-containers.containers.${name} = {
|
virtualisation.oci-containers.containers.${name} = {
|
||||||
inherit image;
|
inherit image;
|
||||||
|
hostname = name;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
environment = {
|
environment = {
|
||||||
PUID = uid;
|
PUID = uid;
|
||||||
|
@ -37,7 +38,7 @@ in
|
||||||
"${volume}/config:/config"
|
"${volume}/config:/config"
|
||||||
"${volume}/downloads:/downloads"
|
"${volume}/downloads:/downloads"
|
||||||
"${volume}/progress:/progress"
|
"${volume}/progress:/progress"
|
||||||
"${volume}/auto:/auto"
|
"${volume}/watch:/watch"
|
||||||
];
|
];
|
||||||
ports = [
|
ports = [
|
||||||
"6881:6881"
|
"6881:6881"
|
||||||
|
|
|
@ -25,6 +25,7 @@ in
|
||||||
|
|
||||||
virtualisation.oci-containers.containers.${name} = {
|
virtualisation.oci-containers.containers.${name} = {
|
||||||
inherit image;
|
inherit image;
|
||||||
|
hostname = name;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
user = "${uid}:${gid}";
|
user = "${uid}:${gid}";
|
||||||
environment = {
|
environment = {
|
||||||
|
|
|
@ -25,6 +25,7 @@ in
|
||||||
|
|
||||||
virtualisation.oci-containers.containers.${name} = {
|
virtualisation.oci-containers.containers.${name} = {
|
||||||
inherit image;
|
inherit image;
|
||||||
|
hostname = name;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
user = "${uid}:${gid}";
|
user = "${uid}:${gid}";
|
||||||
environment = {
|
environment = {
|
||||||
|
|
|
@ -28,6 +28,7 @@ in
|
||||||
|
|
||||||
virtualisation.oci-containers.containers.${name} = {
|
virtualisation.oci-containers.containers.${name} = {
|
||||||
inherit image;
|
inherit image;
|
||||||
|
hostname = name;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
user = "${uid}:${gid}";
|
user = "${uid}:${gid}";
|
||||||
environment = {
|
environment = {
|
||||||
|
@ -56,6 +57,7 @@ in
|
||||||
|
|
||||||
virtualisation.oci-containers.containers.${name-flaresolverr} = {
|
virtualisation.oci-containers.containers.${name-flaresolverr} = {
|
||||||
image = image-flaresolverr;
|
image = image-flaresolverr;
|
||||||
|
hostname = name-flaresolverr;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
environment = {
|
environment = {
|
||||||
TZ = "Asia/Jakarta";
|
TZ = "Asia/Jakarta";
|
||||||
|
|
|
@ -62,6 +62,7 @@ in
|
||||||
|
|
||||||
virtualisation.oci-containers.containers.${name} = {
|
virtualisation.oci-containers.containers.${name} = {
|
||||||
inherit image;
|
inherit image;
|
||||||
|
hostname = name;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
user = "${uid}:${gid}";
|
user = "${uid}:${gid}";
|
||||||
environment = {
|
environment = {
|
||||||
|
|
Loading…
Reference in a new issue