procd: allow passing optional group instance parameter
authorMichael Heimpold <mhei@heimpold.de>
Thu, 11 Apr 2019 19:01:09 +0000 (21:01 +0200)
committerHans Dedecker <dedeckeh@gmail.com>
Thu, 2 May 2019 15:39:16 +0000 (17:39 +0200)
Sometimes is desirable to run a process with a specific group id
instead of the default one which is derived from passwd entry.
This can be achived now by using procd_set_param group $mygroup.

Signed-off-by: Michael Heimpold <mhei@heimpold.de>
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com> [PKG_SOURCE_VERSION update]
package/system/procd/Makefile
package/system/procd/files/procd.sh

index f31c8d0cea9bc4c57943d2b745e2023901524d0b..29a60081603a48a2450905b2f96857c609f78867 100644 (file)
@@ -13,8 +13,8 @@ PKG_RELEASE:=1
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_URL=$(PROJECT_GIT)/project/procd.git
 PKG_SOURCE_DATE:=2019-05-02
-PKG_SOURCE_VERSION:=61a8be6cb4423dde9c7e7262456f4a16752b9abc
-PKG_MIRROR_HASH:=6020e59d1a2983a5039e10fd1f5e7b89f229fefecdff9472729709fccc7cdf43
+PKG_SOURCE_VERSION:=455aca9b9a0c2d603121a7bcae43abd486762bab
+PKG_MIRROR_HASH:=81cd790390a523ea458a7e4f97ebe1a08e68e31b758f1dca81efd1cb8a77d057
 CMAKE_INSTALL:=1
 
 PKG_LICENSE:=GPL-2.0
index 6115f0702f6bfbf0dfc9977bd3569aee0f7a8145..b49b2b9d0194c7aae5f63a3f82b90918218d5060 100644 (file)
@@ -18,7 +18,8 @@
 #     file: configuration files (array)
 #     netdev: bound network device (detects ifindex changes)
 #     limits: resource limits (passed to the process)
-#     user info: array with 1 values $username
+#     user: $username to run service as
+#     group: $groupname to run service as
 #     pidfile: file name to write pid into
 #     stdout: boolean whether to redirect commands stdout to syslog (default: 0)
 #     stderr: boolean whether to redirect commands stderr to syslog (default: 0)
@@ -252,7 +253,7 @@ _procd_set_param() {
                reload_signal)
                        json_add_int "$type" $(kill -l "$1")
                ;;
-               pidfile|user|seccomp|capabilities|facility)
+               pidfile|user|group|seccomp|capabilities|facility)
                        json_add_string "$type" "$1"
                ;;
                stdout|stderr|no_new_privs)