From 5c084953d3d9c8e8c39f8e80525b6f53a038b3fc Mon Sep 17 00:00:00 2001 From: Roman Podoliaka Date: Wed, 11 Sep 2024 22:26:08 +0100 Subject: [PATCH] Fix postgres-backups@.service definition The binary name is "python3", not "python", so the service has been failing. --- roles/postgres/templates/postgres-backups@.service.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/postgres/templates/postgres-backups@.service.j2 b/roles/postgres/templates/postgres-backups@.service.j2 index bd6042c..8952d5b 100644 --- a/roles/postgres/templates/postgres-backups@.service.j2 +++ b/roles/postgres/templates/postgres-backups@.service.j2 @@ -9,4 +9,4 @@ Group = postgres WorkingDirectory = {{ postgres_backups_dir }} ExecStartPre = +/usr/bin/chown postgres:postgres {{ postgres_backups_dir }} ExecStart = /usr/bin/bash -c "/usr/bin/pg_dump --compress=9 --no-owner --format=p --file=%i_$(TZ=UTC date +%%Y%%m%%d-%%H%%M%%S).sql.gz %i" -ExecStartPost = /usr/bin/python /usr/local/bin/rotate.py --keep 30 --dir {{ postgres_backups_dir }} +ExecStartPost = /usr/bin/python3 /usr/local/bin/rotate.py --keep 30 --dir {{ postgres_backups_dir }}