diff --git a/features.in/control/README b/features.in/control/README new file mode 100644 index 00000000..1e72cd2f --- /dev/null +++ b/features.in/control/README @@ -0,0 +1,2 @@ +Эта фича предоставляет интерфейс для конфигурирования дистрибутивных +значений по умолчанию control(8); см. тж. http://altlinux.org/control diff --git a/features.in/control/config.mk b/features.in/control/config.mk new file mode 100644 index 00000000..071912ba --- /dev/null +++ b/features.in/control/config.mk @@ -0,0 +1,8 @@ +use/control: + @$(call add_feature) + @$(call add,THE_PACKAGES,control) + @$(call xport,CONTROL) + +# some presets +use/control/sudo-su: + @$(call add,CONTROL,su:public sudo:public) diff --git a/features.in/control/rootfs/image-scripts.d/50-control b/features.in/control/rootfs/image-scripts.d/50-control new file mode 100755 index 00000000..36f6e9e6 --- /dev/null +++ b/features.in/control/rootfs/image-scripts.d/50-control @@ -0,0 +1,11 @@ +#!/bin/sh +# setup control(8) states + +[ -z "$GLOBAL_CONTROL" ] || + echo "$GLOBAL_CONTROL" \ + | tr ' ' '\n' \ + | while IFS=':' read facility state; do + [ -z "$facility" -o -z "$state" ] || + control "$facility" "$state" + done +: