~charmers/charms/oneiric/mediawiki/trunk

« back to all changes in this revision

Viewing changes to formulas/haproxy/hooks/website-relation-changed

  • Committer: Clint Byrum
  • Date: 2011-05-12 01:52:22 UTC
  • Revision ID: clint@ubuntu.com-20110512015222-f3s57s2eqqah153g
If consumer flags itself as a proxy, mark as such so we can turn off forwarded_for

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/sh
 
2
 
 
3
service=`echo $ENSEMBLE_REMOTE_UNIT | cut -d/ -f1`
 
4
isproxy=`relation-get is-proxy`
 
5
 
 
6
if [ -n "$isproxy" ] ; then
 
7
    touch /etc/haproxy/$service.is.proxy
 
8
fi