39 lines
1.8 KiB
Plaintext
39 lines
1.8 KiB
Plaintext
|
[Unit]
|
||
|
Description=Podman container-music-navidrome.service
|
||
|
Documentation=man:podman-generate-systemd(1)
|
||
|
Wants=network.target
|
||
|
After=network-online.target
|
||
|
BindsTo=pod-music.service
|
||
|
After=pod-music.service
|
||
|
OnFailure=status-mail@%n.service
|
||
|
|
||
|
[Service]
|
||
|
Environment=PODMAN_SYSTEMD_UNIT=%n
|
||
|
Restart=on-failure
|
||
|
TimeoutStopSec=70
|
||
|
ExecStartPre=/bin/rm -f %t/container-music-navidrome.pid %t/container-music-navidrome.ctr-id
|
||
|
ExecStart=/usr/bin/podman run \
|
||
|
--conmon-pidfile %t/container-music-navidrome.pid \
|
||
|
--cidfile %t/container-music-navidrome.ctr-id \
|
||
|
--cgroups=no-conmon \
|
||
|
--pod-id-file %t/pod-music.pod-id \
|
||
|
--replace \
|
||
|
--label "io.containers.autoupdate=image" \
|
||
|
-dt \
|
||
|
-v {{ services_root_directory }}/{{ services_resolv_host }}-resolv.conf:/etc/resolv.conf:ro \
|
||
|
-v {{ services_data_directory }}/pod-music/data/_data:/data \
|
||
|
-v {{ services_host_services[services_service_name].music_path }}:/music:ro \
|
||
|
-e ND_PORT="80" \
|
||
|
-e ND_ENABLESTARRATING="false" \
|
||
|
-e ND_LASTFM_ENABLED="false" \
|
||
|
-e ND_PASSWORDENCRYPTIONKEY={{ services[services_service_name].password_encryption_key }} \
|
||
|
--name=pod-music-navidrome \
|
||
|
docker.io/deluan/navidrome:{{ services_deploy_versions.music.navidrome }}
|
||
|
ExecStop=/usr/bin/podman stop --ignore --cidfile %t/container-music-navidrome.ctr-id -t 10
|
||
|
ExecStopPost=/usr/bin/podman rm --ignore -f --cidfile %t/container-music-navidrome.ctr-id
|
||
|
PIDFile=%t/container-music-navidrome.pid
|
||
|
Type=forking
|
||
|
|
||
|
[Install]
|
||
|
WantedBy=multi-user.target default.target
|