Fix the overriding of static files in dist-git
This commit is contained in:
parent
55cc72d160
commit
d2fa8a904b
1 changed files with 15 additions and 0 deletions
|
@ -66,5 +66,20 @@ SSLCryptoDevice builtin
|
|||
Require valid-user
|
||||
</Location>
|
||||
|
||||
|
||||
# Insert the redirect rules allowing pagure to override some of its static
|
||||
# files. This is pagure related not so much lookaside related but since this
|
||||
# is using a VirtualHost on port 80 we need to group the configs
|
||||
|
||||
# Configure static files so that a custom theme can override the defaults
|
||||
RewriteEngine on
|
||||
|
||||
# Check if the static file exists in the template directory
|
||||
RewriteCond "/usr/share/pagure_dist_git/static/$1" -f
|
||||
# If it does, use it
|
||||
RewriteRule "^/static/(.*)" "/usr/share/pagure_dist_git/static/$1" [L]
|
||||
# Otherwise back out and use the default static folder/theme
|
||||
RewriteRule "^/static/(.*)" "/usr/lib/python2.7/site-packages/pagure/static/$1" [L]
|
||||
|
||||
</VirtualHost>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue