Skip to content

Commit 1dbdfee

Browse files
committed
Fix matrix-postgres stopping for consistency with other services
This probably got lost somehow in all the work that happened in #456
1 parent 9f91eaa commit 1dbdfee

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

roles/matrix-postgres/templates/systemd/matrix-postgres.service.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ DefaultDependencies=no
88
[Service]
99
Type=simple
1010
Environment="HOME={{ matrix_systemd_unit_home_path }}"
11-
ExecStartPre=-{{ matrix_host_command_docker }} stop matrix-postgres
11+
ExecStartPre=-{{ matrix_host_command_sh }} -c '{{ matrix_host_command_docker }} kill matrix-postgres 2>/dev/null'
1212
ExecStartPre=-{{ matrix_host_command_sh }} -c '{{ matrix_host_command_docker }} rm matrix-postgres 2>/dev/null'
1313

1414
ExecStart={{ matrix_host_command_docker }} run --rm --name matrix-postgres \
@@ -34,7 +34,7 @@ ExecStart={{ matrix_host_command_docker }} run --rm --name matrix-postgres \
3434
{{ arg }} \
3535
{% endfor %}
3636

37-
ExecStop=-{{ matrix_host_command_docker }} stop matrix-postgres
37+
ExecStop=-{{ matrix_host_command_sh }} -c '{{ matrix_host_command_docker }} kill matrix-postgres 2>/dev/null'
3838
ExecStop=-{{ matrix_host_command_sh }} -c '{{ matrix_host_command_docker }} rm matrix-postgres 2>/dev/null'
3939
Restart=always
4040
RestartSec=30

0 commit comments

Comments
 (0)