diff --git a/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf b/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf index 77af258e56..8a97f39afa 100644 --- a/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf +++ b/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf @@ -19,6 +19,22 @@ RewriteRule ^/v2/(.*)$ http://oci-registry01:5000/v2/$1 [P,L] {% endif %} RewriteRule ^/v2/(.*)$ http://localhost:6081/v2/$1 [P,L] +RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 +RewriteCond "&%{QUERY_STRING}" &tag=testing +RewriteCond "&%{QUERY_STRING}" &architecture=([^&]+) +RewriteRule "^/index/static$" /index/flatpak-testing-%1.json [L,PT] + +RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 +RewriteCond "&%{QUERY_STRING}" &architecture=([^&]+) +RewriteRule "^/index/static$" /index/flatpak-%1.json [L,PT] + +RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 +RewriteCond "&%{QUERY_STRING}" &tag=testing +RewriteRule "^/index/static$" /index/flatpak-testing.json [L,PT] + +RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 +RewriteRule "^/index/static$" /index/flatpak.json [L,PT] + DocumentRoot /srv/web/registry-index/ @@ -49,25 +65,6 @@ Alias "/app-icons/" "/srv/web/registry-index/icons/" ExpiresActive on ExpiresDefault "access plus 30 minutes" - RewriteEngine on - RewriteBase /index/ - - RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 - RewriteCond "&%{QUERY_STRING}" &tag=testing - RewriteCond "&%{QUERY_STRING}" &architecture=([^&]+) - RewriteRule "static" flatpak-testing-%1.json [L] - - RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 - RewriteCond "&%{QUERY_STRING}" &architecture=([^&]+) - RewriteRule "static" flatpak-%1.json [L] - - RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 - RewriteCond "&%{QUERY_STRING}" &tag=testing - RewriteRule "static" flatpak-testing.json [L] - - RewriteCond "&%{QUERY_STRING}" &annotation(%3A|:)org.flatpak.ref(%3A|:)exists=1 - RewriteRule "static" flatpak.json [L] - AllowOverride None Require all granted