summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuergen Borleis <jbe@pengutronix.de>2017-09-28 10:37:03 +0200
committerMichael Olbrich <m.olbrich@pengutronix.de>2017-10-01 11:11:40 +0200
commit6108bcaa767fc97601c838e9d7f1fa174f35dce8 (patch)
treebc767d6792c364d04cfc6927c233c2a29bdf275c
parent674bd8d1cb306ab83ee21379db192a72eb3464e4 (diff)
downloadptxdist-6108bcaa767fc97601c838e9d7f1fa174f35dce8.tar.gz
ptxdist-6108bcaa767fc97601c838e9d7f1fa174f35dce8.tar.xz
sudo: provide 'sudoers.d' for individual user files
The 'sudoers.d' provides a more flexible way to install individual and independent permission files without using a shared single '/etc/sudoers' file. Signed-off-by: Juergen Borleis <jbe@pengutronix.de> Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r--projectroot/etc/sudoers3
-rw-r--r--rules/sudo.make1
2 files changed, 4 insertions, 0 deletions
diff --git a/projectroot/etc/sudoers b/projectroot/etc/sudoers
index c57a3ef44..b04419c9d 100644
--- a/projectroot/etc/sudoers
+++ b/projectroot/etc/sudoers
@@ -31,3 +31,6 @@ root ALL=(ALL) ALL
# Samples
# %users ALL=/sbin/mount /cdrom,/sbin/umount /cdrom
# %users localhost=/sbin/shutdown -h now
+
+# include other dedicated settings
+#includedir /etc/sudoers.d
diff --git a/rules/sudo.make b/rules/sudo.make
index 6fedc232a..87ebd2c14 100644
--- a/rules/sudo.make
+++ b/rules/sudo.make
@@ -113,6 +113,7 @@ $(STATEDIR)/sudo.targetinstall:
ifdef PTXCONF_SUDO_INSTALL_ETC_SUDOERS
@$(call install_alternative, sudo, 0, 0, 0440, /etc/sudoers, n)
+ @$(call install_copy, sudo, 0, 0, 755, /etc/sudoers.d)
endif
ifdef PTXCONF_SUDO_INSTALL_VISUDO