summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/apache2/sites-available/jenkins.debian.net9
-rwxr-xr-xupdate_jdn.sh1
2 files changed, 9 insertions, 1 deletions
diff --git a/etc/apache2/sites-available/jenkins.debian.net b/etc/apache2/sites-available/jenkins.debian.net
index c26de24d..ddd739ee 100644
--- a/etc/apache2/sites-available/jenkins.debian.net
+++ b/etc/apache2/sites-available/jenkins.debian.net
@@ -21,13 +21,20 @@
Allow from all
</Directory>
+ # allow certain params only from alioth (token is used to trigger builds)
+ RewriteEngine on
+ RewriteCond %{REMOTE_ADDR} !217\.196\.43\.140
+ #RewriteCond %{REMOTE_HOST} !.*.debian.org
+ RewriteCond %{QUERY_STRING} token
+ RewriteRule ^ - [F]
+
ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPreserveHost on
- # proxy everything but /munin
+ # proxy everything but a few urls
ProxyPass /munin !
ProxyPass /server-status !
ProxyPass /visitors-report.html !
diff --git a/update_jdn.sh b/update_jdn.sh
index 8eddb24e..ac90a651 100755
--- a/update_jdn.sh
+++ b/update_jdn.sh
@@ -45,6 +45,7 @@ sudo cp -r etc/* /etc
if [ ! -e /etc/apache2/mods-enabled/proxy.load ] ; then
sudo a2enmod proxy
sudo a2enmod proxy_http
+ sudo a2enmod rewrite
fi
sudo chown root.root /etc/sudoers.d/jenkins ; sudo chmod 700 /etc/sudoers.d/jenkins
sudo ln -sf /etc/apache2/sites-available/jenkins.debian.net /etc/apache2/sites-enabled/000-default