]> git.proxmox.com Git - mirror_ovs.git/blame - rhel/usr_lib_systemd_system_ovsdb-server.service
rhel: Use correct user in the logrotate configuration file
[mirror_ovs.git] / rhel / usr_lib_systemd_system_ovsdb-server.service
CommitLineData
b49c106e 1[Unit]
84ad1208 2Description=Open vSwitch Database Unit
36af136b
AC
3After=syslog.target network-pre.target
4Before=network.target network.service
a694ead1 5Wants=ovs-delete-transient-ports.service
b49c106e 6PartOf=openvswitch.service
b49c106e
FL
7
8[Service]
84ad1208 9Type=forking
c19bf36d 10Restart=on-failure
92d53574 11EnvironmentFile=/etc/openvswitch/default.conf
b49c106e 12EnvironmentFile=-/etc/sysconfig/openvswitch
b096fa42 13ExecStartPre=/usr/bin/chown ${OVS_USER_ID} /var/run/openvswitch /var/log/openvswitch
112b6336 14ExecStartPre=/bin/sh -c 'rm -f /run/openvswitch/useropts; if [ "$${OVS_USER_ID/:*/}" != "root" ]; then /usr/bin/echo "OVSUSER=--ovs-user=${OVS_USER_ID}" > /run/openvswitch/useropts; fi'
4299145c 15EnvironmentFile=-/run/openvswitch/useropts
84ad1208
AC
16ExecStart=/usr/share/openvswitch/scripts/ovs-ctl \
17 --no-ovs-vswitchd --no-monitor --system-id=random \
4299145c 18 ${OVSUSER} \
84ad1208
AC
19 start $OPTIONS
20ExecStop=/usr/share/openvswitch/scripts/ovs-ctl --no-ovs-vswitchd stop
21ExecReload=/usr/share/openvswitch/scripts/ovs-ctl --no-ovs-vswitchd \
4299145c 22 ${OVSUSER} \
84ad1208 23 --no-monitor restart $OPTIONS
51542edd
FL
24RuntimeDirectory=openvswitch
25RuntimeDirectoryMode=0755