summaryrefslogtreecommitdiff
path: root/packaging/debian/monkeysphere.postinst
blob: efa7fb47fd6c3152e03cd5f1c44f8c378c1e7d62 (plain)
  1. #!/bin/sh -e
  2. # postinst script for monkeysphere
  3. # Author: Jameson Rollins <jrollins@finestructure.net>
  4. # Copyright 2008-2009
  5. VARLIB="/var/lib/monkeysphere"
  6. # add a monkeysphere user if one does not already exist
  7. if ! getent passwd monkeysphere >/dev/null ; then
  8. echo "adding monkeysphere user..."
  9. adduser --quiet --system --no-create-home --group \
  10. --home "$VARLIB" \
  11. --shell '/bin/bash' \
  12. --gecos 'monkeysphere authentication user,,,' \
  13. monkeysphere
  14. fi
  15. # try to transition from 0.22 to 0.23:
  16. /usr/share/monkeysphere/transition_0.22_0.23
  17. # setup monkeysphere authentication
  18. monkeysphere-authentication setup
  19. # dh_installdeb will replace this with shell code automatically
  20. # generated by other debhelper scripts.
  21. #DEBHELPER#
  22. exit 0