From 222986940847bef66cfb68709488d5b3413a8bba Mon Sep 17 00:00:00 2001 From: Kevin Fenzi Date: Thu, 30 Aug 2018 16:21:09 +0000 Subject: [PATCH] sync icons and setup httpd config --- .../registry/files/cron-sync-registry-index | 1 + .../reversepassproxy.registry-generic.conf | 42 ++++++++++++++++++- 2 files changed, 42 insertions(+), 1 deletion(-) diff --git a/roles/fedora-web/registry/files/cron-sync-registry-index b/roles/fedora-web/registry/files/cron-sync-registry-index index cc922257e9..a64796346f 100644 --- a/roles/fedora-web/registry/files/cron-sync-registry-index +++ b/roles/fedora-web/registry/files/cron-sync-registry-index @@ -1,2 +1,3 @@ 30 * * * * root /usr/bin/rsync --delete -a --no-owner --no-group sundries01::registry-index/ /srv/web/registry-index/ 40 * * * * root /usr/bin/rsync --delete -a --no-owner --no-group sundries01::regindexer/index/ /srv/web/registry-index/index/ +45 * * * * root /usr/bin/rsync --delete -a --no-owner --no-group sundries01::regindexer/icons/ /srv/web/registry-index/icons/ diff --git a/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf b/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf index 0e4ef7524e..fc9f9f2f62 100644 --- a/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf +++ b/roles/httpd/reverseproxy/templates/reversepassproxy.registry-generic.conf @@ -26,7 +26,6 @@ SSLVerifyDepth 1 SSLCACertificateFile /etc/pki/httpd/registry-ca-{{env}}.cert SSLOptions +FakeBasicAuth - AuthName "Registry Authentication" AuthType Basic @@ -36,3 +35,44 @@ SSLOptions +FakeBasicAuth Require all granted + +Alias "/stable/index/" "/srv/web/registry-index/index/" +Alias "/app-icons/" "/srv/web/registry-index/icons/" + + + Options +FollowSymLinks + + 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 + + + + ExpiresActive on + ExpiresDefault "access plus 1 year" + + AllowOverride None + Options +Indexes + Require all granted +