diff --git a/deploy.sh b/deploy.sh index 17a88bd..1fe08af 100755 --- a/deploy.sh +++ b/deploy.sh @@ -78,10 +78,10 @@ r "systemctl --user status $SERVICE_NAME --no-pager" || true # --- Web backend (reverse proxy) --- -echo "==> Configuring web backend for /agw-api/" -r "uberspace web backend add /agw-api PORT $BACKEND_PORT --remove-prefix --force --wait" 2>/dev/null || true +echo "==> Configuring web backend for /agw/api/" +r "uberspace web backend add /agw/api PORT $BACKEND_PORT --remove-prefix --force --wait" 2>/dev/null || true echo "" echo "Done." echo " PWA: https://$REMOTE_USER.uber.space/agw/" -echo " Backend: https://$REMOTE_USER.uber.space/agw-api/" +echo " Backend: https://$REMOTE_USER.uber.space/agw/api/" diff --git a/public/.htaccess b/public/.htaccess index 401ecad..afd36a7 100644 --- a/public/.htaccess +++ b/public/.htaccess @@ -1,6 +1,9 @@ RewriteEngine On RewriteBase /agw/ +# Let the backend reverse proxy handle /agw/api/ +RewriteRule ^api(/|$) - [L] + # If the requested file or directory exists, serve it directly RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d