File: haproxy.service-make-systemd-bind-dev-log-inside-chroot.patch

package info (click to toggle)
haproxy 3.2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 23,832 kB
  • sloc: ansic: 266,729; sh: 3,275; xml: 1,756; python: 1,345; makefile: 1,151; perl: 168; cpp: 21
file content (21 lines) | stat: -rw-r--r-- 901 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
From: Vincent Bernat <bernat@debian.org>
Date: Thu, 25 Nov 2021 21:35:48 +0100
Subject: haproxy.service: make systemd bind /dev/log inside chroot

This enables logging to work without rsyslog being present.
---
 admin/systemd/haproxy.service.in | 1 +
 1 file changed, 1 insertion(+)

diff --git a/admin/systemd/haproxy.service.in b/admin/systemd/haproxy.service.in
index 0288568..20824df 100644
--- a/admin/systemd/haproxy.service.in
+++ b/admin/systemd/haproxy.service.in
@@ -8,6 +8,7 @@ Wants=network-online.target
 [Service]
 EnvironmentFile=-/etc/default/haproxy
 EnvironmentFile=-/etc/sysconfig/haproxy
+BindReadOnlyPaths=/dev/log:/var/lib/haproxy/dev/log
 Environment="CONFIG=/etc/haproxy/haproxy.cfg" "PIDFILE=/run/haproxy.pid" "EXTRAOPTS=-S /run/haproxy-master.sock"
 ExecStart=@SBINDIR@/haproxy -Ws -f $CONFIG -p $PIDFILE $EXTRAOPTS
 ExecReload=@SBINDIR@/haproxy -Ws -f $CONFIG -c $EXTRAOPTS