set gitlab_user default value in postrm

This commit is contained in:
Praveen Arimbrathodiyil 2017-02-20 18:12:03 +05:30
parent 374c768315
commit d9a8b7a138

2
debian/postrm vendored
View file

@ -53,6 +53,8 @@ case "$1" in
rm -rf ${gitlab_log_dir}
rm -rf ${gitlab_cache_path}
rm -rf ${gitlab_pid_path}
# Don't fail if user is already removed
gitlab_user=${gitlab_user:-gitlab}
id -u ${gitlab_user} && userdel -r ${gitlab_user}
rm -rf ${gitlab_data_dir}
su ${gitlab_user} -c 'psql gitlab_production -c ""' && su postgres -c "dropdb gitlab_production"