1 # ./add-provider.pl www.artstor.org library.artstor.org
6 Include /srv/via-proxy/ssl.conf
8 ServerName www.artstor.org.p.vbz.ffzg.hr
12 #RewriteRule /common/javascript/extjs/ext-all.js https://www.artstor.org/common/javascript/extjs/ext-all.js [R,L]
16 ProxyPass / https://www.artstor.org/
17 ProxyPassReverse / https://www.artstor.org/
19 Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3"
20 #Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1"
21 # if there are problems, remove traling /
22 Header edit* Location "https://www.artstor.org/" "https://www.artstor.org.p.vbz.ffzg.hr/"
23 Header edit* Location "https://library.artstor.org/" "https://library.artstor.org.p.vbz.ffzg.hr/"
25 RequestHeader unset Accept-Encoding
26 Substitute "s|https://www.artstor.org|https://www.artstor.org.p.vbz.ffzg.hr|"
27 Substitute "s|https://library.artstor.org|https://library.artstor.org.p.vbz.ffzg.hr|"
29 FilterDeclare NEWPATHS
30 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/html|"
31 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/css|"
32 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|"
33 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|"
36 CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined
41 Include /srv/via-proxy/ssl.conf
43 ServerName library.artstor.org.p.vbz.ffzg.hr
47 #RewriteRule /common/javascript/extjs/ext-all.js https://library.artstor.org/common/javascript/extjs/ext-all.js [R,L]
51 ProxyPass / https://library.artstor.org/
52 ProxyPassReverse / https://library.artstor.org/
54 Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3"
55 #Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1"
56 # if there are problems, remove traling /
57 Header edit* Location "https://www.artstor.org/" "https://www.artstor.org.p.vbz.ffzg.hr/"
58 Header edit* Location "https://library.artstor.org/" "https://library.artstor.org.p.vbz.ffzg.hr/"
60 RequestHeader unset Accept-Encoding
61 Substitute "s|https://www.artstor.org|https://www.artstor.org.p.vbz.ffzg.hr|"
62 Substitute "s|https://library.artstor.org|https://library.artstor.org.p.vbz.ffzg.hr|"
64 Substitute "s|/(\w+\.[0-9a-f]+.js)|https://library.artstor.org/$1|i"
66 FilterDeclare NEWPATHS
67 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/html|"
68 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/css|"
69 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|"
70 FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|"
73 CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined
77 ## add domains to SSL certificate:
78 # www.artstor.org.p.vbz.ffzg.hr
79 # library.artstor.org.p.vbz.ffzg.hr