diff options
| author | Paul Buetow (lxpbuetow.webde.local) <paul.buetow@1und1.de> | 2014-07-14 13:12:24 +0200 |
|---|---|---|
| committer | Paul Buetow (lxpbuetow.webde.local) <paul.buetow@1und1.de> | 2014-07-14 13:12:24 +0200 |
| commit | a5f5f04cf76f159342777f95dabee2d3aff8dd10 (patch) | |
| tree | 5b53e55759b5c0dd011893e3db31f6cfc4f1ab93 /src | |
| parent | d1f3649e1a91492250221ac8515a844888362c8d (diff) | |
| parent | 6799dbf086f147e1d15f39a5d1cdc5a4e892bc8b (diff) | |
Merge branch 'master' into develop
Diffstat (limited to 'src')
| -rwxr-xr-x | src/fapi | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -122,7 +122,7 @@ class FapiBase(object): ' -f Common -b balancer.example.com selfip', ' -f Common -b balancer.example.com selfip NAME create NETMASK VLANNAME [TGROUP]', ' -f Common -b balancer.example.com selfip NAME delete', - ' -f Common -b balancer.example.com selfip NAME get detail|tgroup', + ' -f Common -b balancer.example.com selfip NAME get address|detail|tgroup', ' -f Common -b balancer.example.com selfip NAME set tgroup TGROUP', ' -f Common -b balancer.example.com vlan', ' -f Common -b balancer.example.com vlan NAME create tagged VLANID internal|external|...', @@ -420,17 +420,17 @@ class Fapi(FapiBase): a = self._args if not a.name: return lambda: f5().get_list() - # Check for Pattern like /partition/foo-bar.example.com_443 - m = re.match('^(.*)_(\d+)$', a.name) - if m: - fqdn_or_ip = m.group(1) - port = m.group(2) - _, ip, _ = self.lookup(fqdn_or_ip) - else: - fqdn_or_ip, ip, port = self.lookup(a.name) if a.a: - name = fqdn_or_ip + name = a.name else: + # Check for Pattern like /partition/foo-bar.example.com_443 + m = re.match('^(.*)_(\d+)$', a.name) + if m: + fqdn_or_ip = m.group(1) + port = m.group(2) + _, ip, _ = self.lookup(fqdn_or_ip) + else: + fqdn_or_ip, ip, port = self.lookup(a.name) name = fqdn_or_ip + '_' + port if a.sub == 'get': if a.sub2 == 'detail': |
