diff options
| author | Jan Tuomi <jan@jantuomi.fi> | 2026-08-05 13:53:07 +0300 |
|---|---|---|
| committer | Jan Tuomi <jan@jantuomi.fi> | 2026-08-05 14:38:00 +0300 |
| commit | 469afb98140c2a33ecd0124381035423a2006e1e (patch) | |
| tree | c3e234437df915d47831829d3e34671b82be8ef2 /roles/jails/20_immich/templates | |
| parent | d38fe54ab035f8e3248b8e20a58abd89861833bf (diff) | |
Restructure jail ip references
Diffstat (limited to 'roles/jails/20_immich/templates')
| -rw-r--r-- | roles/jails/20_immich/templates/jail.conf.j2 | 12 | ||||
| -rw-r--r-- | roles/jails/20_immich/templates/usr_local_etc_immich_server.env.j2 | 4 |
2 files changed, 8 insertions, 8 deletions
diff --git a/roles/jails/20_immich/templates/jail.conf.j2 b/roles/jails/20_immich/templates/jail.conf.j2 index 8e3c626..fb7f363 100644 --- a/roles/jails/20_immich/templates/jail.conf.j2 +++ b/roles/jails/20_immich/templates/jail.conf.j2 @@ -1,4 +1,4 @@ -immich { +{{ jail.name }} { vnet; persist; exec.clean; @@ -20,13 +20,13 @@ immich { exec.stop = "/bin/sh /etc/rc.shutdown"; # Networking - exec.prestart += "jail_net prestart {{ jail_num }} ${name}"; - exec.poststart += "jail_net poststart {{ jail_num }} ${name}"; - exec.prestop += "jail_net prestop {{ jail_num }} ${name}"; - exec.poststop += "jail_net poststop {{ jail_num }} ${name}"; + exec.prestart += "jail_net prestart ${name} {{ jail.num }} {{ jail.ip }}"; + exec.poststart += "jail_net poststart ${name} {{ jail.num }} {{ jail.ip }}"; + exec.prestop += "jail_net prestop ${name} {{ jail.num }} {{ jail.ip }}"; + exec.poststop += "jail_net poststop ${name} {{ jail.num }} {{ jail.ip }}"; # nullfs mounts -{% for mount in nullfs | default([]) | normalize_nullfs %} +{% for mount in jail.nullfs %} mount += "{{ mount.src }} ${path}{{ mount.dst }} nullfs {{ mount.mode | default('rw') }} 0 0"; {% endfor %} {% for img in oci_images %} diff --git a/roles/jails/20_immich/templates/usr_local_etc_immich_server.env.j2 b/roles/jails/20_immich/templates/usr_local_etc_immich_server.env.j2 index 87c563d..5712234 100644 --- a/roles/jails/20_immich/templates/usr_local_etc_immich_server.env.j2 +++ b/roles/jails/20_immich/templates/usr_local_etc_immich_server.env.j2 @@ -5,14 +5,14 @@ IMMICH_PORT=80 NODE_ENV=production # Database -DB_HOSTNAME={{ jail_lan_cidr | ipv4_nth(2 + jail_lan_offset | int) }} +DB_HOSTNAME={{ jail_ips.postgres }} DB_PORT=5432 DB_USERNAME=immich DB_PASSWORD={{ pg_user_passwords.immich }} DB_DATABASE_NAME=immich # Redis -REDIS_HOSTNAME={{ jail_lan_cidr | ipv4_nth(9 + jail_lan_offset | int) }} +REDIS_HOSTNAME={{ jail_ips.redis }} REDIS_PORT=6379 REDIS_PASSWORD={{ valkey_password }} |
