From ac4018f7b85469e378985351d1d7e88e8a9e7a68 Mon Sep 17 00:00:00 2001 From: Aleksander Mistewicz Date: Tue, 26 Jul 2016 12:52:11 +0200 Subject: [PATCH] Add tsp/tsp-sudoer Syntax error in any file used by sudo will break it. Always check it as in example below: visudo -c -f tsp/tsp-sudoer Change-Id: Icb7978c31370924d1f1928a711de86283022aa4c Signed-off-by: Aleksander Mistewicz --- tsp/tsp-sudoer | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 tsp/tsp-sudoer diff --git a/tsp/tsp-sudoer b/tsp/tsp-sudoer new file mode 100644 index 0000000..cc786c1 --- /dev/null +++ b/tsp/tsp-sudoer @@ -0,0 +1,29 @@ +# Commands used by TITS +# +# tune2fs by tct/*_prepare_flash_conf.sh in tct/flash/flash.sh: change_uuid() +# btrfs by tct/run_tct_chroot.sh in tct/run/run.sh: create_chroot(), delete_chroot() +# chroot by tct/run_tct_chroot.sh in tct/run/run.sh: run_in_chroot() +# mkdir, cp, ln, sh by tct/odroid_prepare_flash_conf.sh in tct/prepare/prepare.sh: install_iserial() +# and test/tct_prepare.bats +# mount, umount by tct/odroid_prepare_flash_conf.sh in tct/prepare/prepare.sh: mount_image(), unmount_image() +# and tct/run_tct_chroot.sh in tct/run/run.sh: create_chroot(), delete_chroot() +# dd by tct/odroid_prepare_flash_conf.sh +# bmaptool by tct/minnow_prepare_flash_conf.sh +# rm by test/tct_flash.bats +Cmnd_Alias C_TSP = \ + /sbin/tune2fs *, \ + /sbin/btrfs subvolume *, \ + /usr/sbin/chroot *, \ + /bin/mkdir *, \ + /bin/cp *, \ + /bin/rm *, \ + /bin/ln -s *, \ + /bin/dd *, \ + /bin/sh -c echo * > */etc/id*, \ + /bin/mount -o loop *, \ + /bin/umount *, \ + /usr/bin/bmaptool -q copy * + +Runas_Alias R_ROOT = root + +%tsp ALL = (R_ROOT) NOPASSWD: C_TSP -- 2.7.4