Mailu / helm-charts

Development repo for helm charts
126 stars 130 forks source link

Delete user script for kubernetes #271

Open GSimonHU opened 1 year ago

GSimonHU commented 1 year ago

Environment & Version

Environment

Version

Description

Cannot delete users in kubernetes env using the purge_user.sh (for docker-compose usage) from https://github.com/Mailu/Mailu/blob/master/scripts/purge_user.sh as a basis.

I managed to remove user from mailu admin pod by exec-ing into the pod and running flask user-delete:

kubectl exec -it -n mailu $mailu-admin-pod-name -- bash

flask mailu user-delete -r user@example.om

But was not able to run the in the webmail pod the the /var/www/roundcube/bin/deluser.sh script

Replication Steps

Exec into the webmail pod

kubectl exec -it -n mailu $mailu-webmail-pod-name -- bash

cd /var/www/roundcube/bin ./deluser.sh --host=front 'user@example.com'

Observed behaviour

[05-Jul-2023 12:15:31 Europe/Berlin] PHP Fatal error: [snuffleupagus][0.0.0.0][readonly_exec][drop] Attempted execution of a writable file (/var/www/roundcube/bin/deluser.sh) in /var/www/roundcube/bin/deluser.sh on line 22

Expected behaviour

Delete the user

Already tried this solution (https://github.com/Mailu/Mailu/issues/2836) and did not work

fastlorenzo commented 1 year ago

Thanks for the report, looks like an issue that should be reported in Mailu repo directly https://github.com/Mailu/Mailu/issues