Skip to content

Commit a0c970e

Browse files
committed
Fix debian postgresql service name
As we can see below we can't rely on `postgresql.service` to propagate correctly all actions in all circumstances to `[email protected]`. It's perhaps due to the fact that `postgresql.service` is configured with (see `systemctl cat postgresql.service` for more details): ``` [Service] Type=oneshot ExecStart=/bin/true ExecReload=/bin/true RemainAfterExit=on ``` So it's safer to target explicitely the final service name (e.g.:`[email protected]`). Case not OK: ``` systemctl is-active postgresql.service active systemctl is-active [email protected] active systemctl stop [email protected] systemctl is-active [email protected] inactive systemctl is-active postgresql.service active ``` Case OK: ``` systemctl start [email protected] systemctl is-active [email protected] active systemctl is-active postgresql.service active systemctl stop postgresql.service systemctl is-active postgresql.service inactive systemctl is-active [email protected] inactive ```
1 parent 048fe10 commit a0c970e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

vars/Debian.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
# PostgreSQL vars for Debian based distributions
33

4-
postgresql_service_name: "postgresql"
4+
postgresql_service_name: "postgresql@{{ postgresql_version }}-{{ postgresql_cluster_name }}"
55

66
postgresql_bin_directory: /usr/bin
77

0 commit comments

Comments
 (0)