summaryrefslogtreecommitdiffstats
path: root/filehooker/root-image/root
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2014-03-24 18:40:53 +0100
committermakefu <github@syntax-fehler.de>2014-03-24 18:40:53 +0100
commit1610072ff0aac8de91c7bf3919bfd75b5fba0e6c (patch)
treec6b7676151256c37aa2e5d7d7dc05471734fa4b9 /filehooker/root-image/root
parent416559761c751427c0b4116145575e0965283857 (diff)
add all the minor tweaks to filehooker
Diffstat (limited to 'filehooker/root-image/root')
-rwxr-xr-xfilehooker/root-image/root/customize_root_image.sh10
1 files changed, 6 insertions, 4 deletions
diff --git a/filehooker/root-image/root/customize_root_image.sh b/filehooker/root-image/root/customize_root_image.sh
index 97f625ee..11912644 100755
--- a/filehooker/root-image/root/customize_root_image.sh
+++ b/filehooker/root-image/root/customize_root_image.sh
@@ -3,7 +3,7 @@
set -e -u -f -x
reaktor_user=reaktor
ncdc_user=hooker
-
+rootpw=$(dd if=/dev/urandom count=1 bs=128 | base64 -w0)
sed -i 's/#\(en_US\.UTF-8\)/\1/' /etc/locale.gen
locale-gen
@@ -46,13 +46,15 @@ test ! -e /krebs/painload/Reaktor && \
useradd $reaktor_user || :
## needed to see the hidden service hostname
-echo "$reaktor_user ALL=(tor) NOPASSWD: /krebs/bin/tor-get-hidden-service.sh" >> /etc/sudoers.d/get_root
-
+echo "$reaktor_user ALL=(tor) NOPASSWD: /krebs/bin/tor-get-hidden-service.sh" >> /etc/sudoers.d/reaktor
+echo "$reaktor_user ALL=(root) NOPASSWD: /krebs/bin/refresh-shares.ship" >> /etc/sudoers.d/reaktor
+echo "$reaktor_user ALL=($ncdc_user) NOPASSWD: ALL" >> /etc/sudoers.d/reaktor
+echo
cp /krebs/painload/Reaktor/etc/systemd/system/Reaktor@.service \
/etc/systemd/system
# add bonus features for filehooker
cp -a /krebs/etc/Reaktor /krebs/painload
-
+(printf "%s\n%s\n" "$rootpw" "$rootpw" ) | passwd
for i in multi-user.target \
pacman-init.service \
choose-mirror.service \