Skip to content

Commit

Permalink
Fix race in haproxy startup
Browse files Browse the repository at this point in the history
  • Loading branch information
baszoetekouw committed Dec 17, 2024
1 parent 4f4c9f3 commit 2b64839
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion roles/lb_haproxy/files/haproxy-log-bindmount.conf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# haproxy runs in a chroot, so make sure the journald log socket is available there
[Service]
# fix log device (points to systemd, but needs to be in the chroot
ExecStartPre=+/bin/touch /var/lib/haproxy/dev/log
ExecStartPre=+sh -c 'test -e /var/lib/haproxy/dev/log || /bin/touch /var/lib/haproxy/dev/log'
ExecStartPre=+/bin/mount -obind /run/systemd/journal/dev-log /var/lib/haproxy/dev/log
ExecStopPost=-+/bin/umount /var/lib/haproxy/dev/log
ExecStopPost=-+/bin/rm -f /var/lib/haproxy/dev/log

0 comments on commit 2b64839

Please sign in to comment.