2016-10-25 14:24:53 +03:00
#!/bin/bash
2016-02-01 17:00:34 +02:00
# postinst script for ahenk
#
# see: dh_installdeb(1)
set -e
case "$1" in
configure)
2016-06-17 18:21:24 +03:00
while true; do
2016-06-20 11:57:40 +03:00
read -p "Eğer makinada var olan bir pam konfigurasyonu varsa geçersiz hale gelecektir.Devam etmek istiyor musunuz? [e/H]" eH
case $eH in
[e] )
2016-10-25 14:24:53 +03:00
if [ -d /usr/share/pam-configs ]
2016-06-17 18:21:24 +03:00
then
2016-10-25 14:24:53 +03:00
echo -e "Name: Support for authentication by external scripts\nDefault: yes\nPriority: 257\nSession-Type: Additional\nSession:\n\toptional\tpam_script.so" > /usr/share/pam-configs/pam_script
DEBIAN_FRONTEND=noninteractive pam-auth-update
2016-06-17 18:21:24 +03:00
fi
break;;
2016-06-20 11:57:40 +03:00
[H] ) exit;;
* ) echo "Lütfen e ya da H karakterleri ile yanı tlayı n!";;
2016-06-17 18:21:24 +03:00
esac
done
2016-02-01 17:00:34 +02:00
systemctl --system daemon-reload
systemctl enable ahenk.service
update-rc.d ahenk defaults
/etc/init.d/ahenk start
;;
abort-upgrade|abort-remove|abort-deconfigure)
;;
*)
echo "postinst called with unknown argument \`$1'" >&2
exit 1
;;
esac
exit 0