diff --git a/etc/apache2/conf-available/phpMyAdmin.conf b/etc/apache2/conf-available/phpMyAdmin.conf index 6e82830..d6dc91f 100644 --- a/etc/apache2/conf-available/phpMyAdmin.conf +++ b/etc/apache2/conf-available/phpMyAdmin.conf @@ -4,11 +4,19 @@ AddExternalAuth pwauth /usr/sbin/pwauth SetExternalAuthMethod pwauth pipe - AuthType Basic - AuthName "phpMyAdmin" - AuthBasicProvider external - AuthExternal pwauth - Require valid-user + # force https + + RewriteEngine On + RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] + + # require auth + + AuthType Basic + AuthName "phpMyAdmin" + AuthBasicProvider external + AuthExternal pwauth + Require valid-user + # this is to force the default fpm, so we don't end up trying to use a virtualhosts jailed fpm which won't work