diff options
author | Holger Levsen <holger@layer-acht.org> | 2012-12-08 15:34:53 +0100 |
---|---|---|
committer | Holger Levsen <holger@layer-acht.org> | 2012-12-08 15:34:53 +0100 |
commit | ceaa417fad1acc400c610f17e2e59852aa5fe209 (patch) | |
tree | 841e9a1573056712efb00d519d1ec82d9f032988 | |
parent | 38898405e7f65b75cb93e081466dd1fe2632ea97 (diff) | |
download | jenkins.debian.net-ceaa417fad1acc400c610f17e2e59852aa5fe209.tar.xz |
allow certain params only from alioth (token is used to trigger builds)
-rw-r--r-- | etc/apache2/sites-available/jenkins.debian.net | 9 | ||||
-rwxr-xr-x | update_jdn.sh | 1 |
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 |