diff options
author | thompsa <andy@fud.org.nz> | 2010-03-05 13:30:18 +1300 |
---|---|---|
committer | thompsa <andy@fud.org.nz> | 2010-03-05 13:30:18 +1300 |
commit | 012cd354237bda4768a7cd62ad902f0841fb78bb (patch) | |
tree | c6d33e71d1b6b215fbea70458e80c6b6bf0c290b /config | |
parent | b80ebd2d768d5c3f8139af0eb7fce6b55d7ad059 (diff) | |
download | pfsense-packages-012cd354237bda4768a7cd62ad902f0841fb78bb.tar.gz pfsense-packages-012cd354237bda4768a7cd62ad902f0841fb78bb.tar.bz2 pfsense-packages-012cd354237bda4768a7cd62ad902f0841fb78bb.zip |
Make the acl name unique by prefixing with <n++>_
Diffstat (limited to 'config')
-rw-r--r-- | config/haproxy-dev/haproxy.inc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/config/haproxy-dev/haproxy.inc b/config/haproxy-dev/haproxy.inc index 12920103..4207a3ca 100644 --- a/config/haproxy-dev/haproxy.inc +++ b/config/haproxy-dev/haproxy.inc @@ -374,6 +374,7 @@ function haproxy_configure() { fwrite ($fd, "\tdefault_backend\t\t" . $bind['defaultpool'] . "\n"); // Combine the rest of the listener configs + $i = 0; foreach ($bind['config'] as $bconfig) { $a_acl=&$bconfig['ha_acls']['item']; if(!is_array($a_acl)) @@ -400,8 +401,10 @@ function haproxy_configure() { else $expr = $entry['expression'] . " " . $entry['value']; - fwrite ($fd, "\tacl\t\t\t".$entry['name']."\t".$expr."\n"); - fwrite ($fd, "\tuse_backend\t\t$poolname if " . $entry['name'] . "\n"); + $aclname = $i . "_" . $entry['name']; + fwrite ($fd, "\tacl\t\t\t" . $aclname . "\t" . $expr . "\n"); + fwrite ($fd, "\tuse_backend\t\t" . $poolname . " if " . $aclname . "\n"); + $i++; } } |