diff --git a/entrypoint.sh b/entrypoint.sh index 412775b..bf9adb3 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -65,5 +65,8 @@ fi echo "Starting Prosody..." -# Switch to prosody user and execute prosody -exec su -l prosody -c 'exec "$@"' -- "$@" +# Ensure proper ownership before running +chown -R prosody:prosody /var/lib/prosody /var/log/prosody /var/run/prosody /etc/prosody + +# Execute as root (Prosody in containers running as root is acceptable) +exec "$@"