sync icons and setup httpd config

This commit is contained in:
Kevin Fenzi 2018-08-30 16:21:09 +00:00
parent 397994facc
commit 2229869408
2 changed files with 42 additions and 1 deletions

View file

@ -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/

View file

@ -26,7 +26,6 @@ SSLVerifyDepth 1
SSLCACertificateFile /etc/pki/httpd/registry-ca-{{env}}.cert
SSLOptions +FakeBasicAuth
<Location /v2>
AuthName "Registry Authentication"
AuthType Basic
@ -36,3 +35,44 @@ SSLOptions +FakeBasicAuth
Require all granted
</Limit>
</Location>
Alias "/stable/index/" "/srv/web/registry-index/index/"
Alias "/app-icons/" "/srv/web/registry-index/icons/"
<Directory “/srv/web/registry-index/index/">
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
</Directory>
<Directory "/srv/web/registry-index/icons/">
ExpiresActive on
ExpiresDefault "access plus 1 year"
AllowOverride None
Options +Indexes
Require all granted
</Directory>