summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2018-09-01 14:43:21 +0200
committerChristian Poessinger <christian@poessinger.com>2018-09-01 14:43:21 +0200
commitbd2f3a42ec9fafdd133d78faa385a19a656f7240 (patch)
tree9c74803bc07e83dc47f1afd99cdd6e9d2ecf7897 /src
parenta5b70e5a9176043ada3749775dce51dd864f6b50 (diff)
downloadvyos-1x-bd2f3a42ec9fafdd133d78faa385a19a656f7240.tar.gz
vyos-1x-bd2f3a42ec9fafdd133d78faa385a19a656f7240.zip
snmp.py: bugfix writing rocommunity string in config
Diffstat (limited to 'src')
-rwxr-xr-xsrc/conf_mode/snmp.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/conf_mode/snmp.py b/src/conf_mode/snmp.py
index 924c19754..86a10c496 100755
--- a/src/conf_mode/snmp.py
+++ b/src/conf_mode/snmp.py
@@ -273,9 +273,9 @@ def get_config():
if conf.exists('community {0} network'.format(name)):
for addr in conf.return_values('community {0} network'.format(name)):
if vyos.validate.is_ipv4(addr):
- community['network_v4'] = addr
+ community['network_v4'].append(addr)
else:
- community['network_v6'] = addr
+ community['network_v6'].append(addr)
snmp['communities'].append(community)