roles/7dtd/tasks/main.yml: add lgsm dir + template tasks + bind mount for config-lgsm - deploys config each run
This commit is contained in:
@@ -41,6 +41,25 @@
|
||||
group: '1000'
|
||||
mode: '0644'
|
||||
|
||||
# LinuxGSM reads config-lgsm/sdtdserver/sdtdserver.cfg on EVERY invocation (start/monitor/stop).
|
||||
# Bind-mounting it makes the role the owner of that config (see vars.yml sdtd_lgsm_querymode);
|
||||
# a previously unmanaged podman volume left defaults in place, causing the monitor crash-loop.
|
||||
- name: Create 7 Days to Die LGSM config directory (container user)
|
||||
ansible.builtin.file:
|
||||
path: /opt/apps/7dtd/lgsm
|
||||
state: directory
|
||||
owner: '1000'
|
||||
group: '1000'
|
||||
mode: '0755'
|
||||
|
||||
- name: Template 7 Days to Die LGSM config from vars.yml
|
||||
ansible.builtin.template:
|
||||
src: sdtdserver.cfg.j2
|
||||
dest: /opt/apps/7dtd/lgsm/sdtdserver.cfg
|
||||
owner: '1000'
|
||||
group: '1000'
|
||||
mode: '0644'
|
||||
|
||||
- name: Deploy 7 Days to Die Server
|
||||
containers.podman.podman_container:
|
||||
image: "{{ sdtd_image }}"
|
||||
@@ -52,6 +71,7 @@
|
||||
volumes:
|
||||
- /opt/apps/7dtd/data:/home/sdtdserver/.local/share/7DaysToDie:z
|
||||
- /opt/apps/7dtd/serverfiles:/home/sdtdserver/serverfiles:z
|
||||
- /opt/apps/7dtd/lgsm:/home/sdtdserver/lgsm/config-lgsm/sdtdserver:z
|
||||
ports:
|
||||
# Required: game port (TCP+UDP), Steam query/beacon ports (UDP)
|
||||
- "26900:26900/tcp"
|
||||
|
||||
Reference in New Issue
Block a user