Delete SOGo data on user removal

tags/ipasserelle-groupware-0.2.37-1
Daniel Berteaud 12 years ago
parent 9efb51be7a
commit aaf8a30688
  1. 1
      createlinks
  2. 16
      root/etc/e-smith/events/actions/sogo-delete-user

@ -20,6 +20,7 @@ safe_symlink("restart", "root/etc/e-smith/events/email-update/services2adjust/my
event_link("sogo-delete-backup", "pre-backup", "60");
event_link("sogo-delete-backup", "post-backup", "60");
event_link("sogo-backup", "pre-backup", "70");
event_link("sogo-delete-user", "user-delete", "10");
panel_link("sogo", "manager");

@ -0,0 +1,16 @@
#!/bin/bash
EVENT=$1
USER=$2
if [ -z "$EVENT" ]; then
echo "event name is missing"
exit 1
fi
if [ -z "$USER" ]; then
echo "user account is missing"
exit 1
fi
su - sogo -c "/usr/sbin/sogo-tool remove $USER" > /dev/null 2>&1
Loading…
Cancel
Save