File 0001-Run-openvswitch-as-openvswitch-openvswitch.patch of Package openvswitch.31517

From 4de3a6e6fc67125a900913598344881c0b0bed71 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jaime=20Caama=C3=B1o=20Ruiz?= <jcaamano@suse.com>
Date: Fri, 8 May 2020 11:15:57 +0200
Subject: [PATCH] Run openvswitch as openvswitch:openvswitch

Change default run configuration to unprivilieged user openvswitch and
group openvswitch. Expect any further customization from user in
sysconfig/openvswitch, including setting it back to privileged root:root
configuration.
---
 rhel/etc_logrotate.d_openvswitch  | 2 +-
 rhel/etc_openvswitch_default.conf | 3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/rhel/etc_logrotate.d_openvswitch b/rhel/etc_logrotate.d_openvswitch
index f4302ffbc..eaf1fd5bf 100644
--- a/rhel/etc_logrotate.d_openvswitch
+++ b/rhel/etc_logrotate.d_openvswitch
@@ -6,7 +6,7 @@
 # without warranty of any kind.
 
 /var/log/openvswitch/*.log {
-    su root root
+    su openvswitch openvswitch
     daily
     compress
     sharedscripts
diff --git a/rhel/etc_openvswitch_default.conf b/rhel/etc_openvswitch_default.conf
index c74417db6..20d1f5f54 100644
--- a/rhel/etc_openvswitch_default.conf
+++ b/rhel/etc_openvswitch_default.conf
@@ -1,5 +1,4 @@
 # DO NOT EDIT THIS FILE
 
 # The following is the *default* configuration for the openvswitch user ID.
-# This is for backward compatibility.
-OVS_USER_ID="root:root"
+OVS_USER_ID="openvswitch:openvswitch"
-- 
2.16.4

openSUSE Build Service is sponsored by