Message ID | 20190610162705.28745-1-jcaamano@suse.com |
---|---|
State | Superseded |
Headers | show |
Series | [ovs-dev,1/2] rhel: set useropts optional for ovsdb-server | expand |
On Mon, Jun 10, 2019 at 06:27:04PM +0200, Jaime Caamaño Ruiz wrote: > systemd assesses the presssence of all EnvironmentFile before execution > of Exec* directives, thus useropts needs to be optional even though it > will always be created at ExecStartPre. > > Problem introduced with commit 94e1e8be3. > > Signed-off-by: Jaime Caamaño Ruiz <jcaamano@suse.com> Would you mind reposting after converting the "Problem introduced with commit 94e1e8be3." line into a Fixes tag for these patches, e.g.: Fixes: 94e1e8be3187 ("rhel: run ovn with the same user as ovs") I have a git-fixes script I use to generate these tags, which is just this one-liner: git --no-pager log -1 --pretty=format:"CC: %an <%ae>%nFixes: %h (\"%s\")%n" --abbrev=12 "$@"
diff --git a/rhel/usr_lib_systemd_system_ovsdb-server.service b/rhel/usr_lib_systemd_system_ovsdb-server.service index a6de4d3c1..4c170c09b 100644 --- a/rhel/usr_lib_systemd_system_ovsdb-server.service +++ b/rhel/usr_lib_systemd_system_ovsdb-server.service @@ -14,7 +14,7 @@ EnvironmentFile=-/etc/sysconfig/openvswitch ExecStartPre=-/usr/bin/chown ${OVS_USER_ID} /var/run/openvswitch /var/log/openvswitch ExecStartPre=/bin/sh -c 'rm -f /run/openvswitch.useropts; /usr/bin/echo "OVS_USER_ID=${OVS_USER_ID}" > /run/openvswitch.useropts' ExecStartPre=/bin/sh -c 'if [ "$${OVS_USER_ID/:*/}" != "root" ]; then /usr/bin/echo "OVS_USER_OPT=--ovs-user=${OVS_USER_ID}" >> /run/openvswitch.useropts; fi' -EnvironmentFile=/run/openvswitch.useropts +EnvironmentFile=-/run/openvswitch.useropts ExecStart=/usr/share/openvswitch/scripts/ovs-ctl \ --no-ovs-vswitchd --no-monitor --system-id=random \ ${OVS_USER_OPT} \
systemd assesses the presssence of all EnvironmentFile before execution of Exec* directives, thus useropts needs to be optional even though it will always be created at ExecStartPre. Problem introduced with commit 94e1e8be3. Signed-off-by: Jaime Caamaño Ruiz <jcaamano@suse.com> --- rhel/usr_lib_systemd_system_ovsdb-server.service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)