debian package setup is more compliant than before

This commit is contained in:
lars 2005-11-30 03:39:17 +00:00
parent f9142cd386
commit 253fb1f06a
3 changed files with 17 additions and 2 deletions

10
DEBIAN/postinst Executable file
View File

@ -0,0 +1,10 @@
#!/bin/sh
# add the cryptobox startup script to /etc/rc?.d
update-rc.d cryptobox 98
# start it
if invoke-rc.d cryptobox status
then invoke-rc.d cryptobox restart
else invoke-rc.d cryptobox start
fi

7
DEBIAN/prerm Executable file
View File

@ -0,0 +1,7 @@
#!/bin/sh
# shut down
invoke-rc.d cryptobox stop
# remove symlinks in /etc/rc?.d
[ "$1" = "purge" ] && update-rc.d cryptobox remove

View File

@ -38,8 +38,6 @@ function configure_normal()
# the usual stuff - not optimized for security # the usual stuff - not optimized for security
{ {
########### boot up ########### ########### boot up ###########
# set default runlevel to 3
sed -i 's/^id:2:initdefault/id:3:initdefault/' /etc/inittab
# turn off creation of "/etc/nologin" (read-only fs) # turn off creation of "/etc/nologin" (read-only fs)
sed -i '/^DELAYLOGIN=/s/^DELAYLOGIN=.*$/DELAYLOGIN=no/' /etc/default/rcS sed -i '/^DELAYLOGIN=/s/^DELAYLOGIN=.*$/DELAYLOGIN=no/' /etc/default/rcS
# turn off modifying /etc/motd (read-only fs) # turn off modifying /etc/motd (read-only fs)