infrastructure-ng/id.tjo.space/root/etc/containers/systemd/postgresql.container

22 lines
592 B
Text

[Unit]
Description=A Postgresql Container
[Container]
# Make sure the postgres image/version matches the one in backup service.
Image=docker.io/postgres:17.4
Volume=/srv/postgresql/data:/var/lib/postgresql/data
EnvironmentFile=/etc/postgresql/secrets.env
Environment=POSTGRES_USER=id.tjo.space
Environment=POSTGRES_DB=id.tjo.space
Network=main.network
AutoUpdate=registry
HealthCmd=pg_isready -d $${POSTGRES_DB} -U $${POSTGRES_USER}
HealthStartPeriod=20s
[Service]
Restart=always
[Install]
WantedBy=multi-user.target
RequiredBy=authentik-server.service
RequiredBy=authentik-worker.service