From ed2c13d86f882f4139064244967f8cca93183d6a Mon Sep 17 00:00:00 2001 From: Qi Luo Date: Wed, 11 Apr 2018 03:02:20 +0000 Subject: [PATCH] Bind snmpd to all ip addresses Signed-off-by: Qi Luo --- dockers/docker-snmp-sv2/snmpd.conf.j2 | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/dockers/docker-snmp-sv2/snmpd.conf.j2 b/dockers/docker-snmp-sv2/snmpd.conf.j2 index b46871dfd6f8..18b7af1e925d 100644 --- a/dockers/docker-snmp-sv2/snmpd.conf.j2 +++ b/dockers/docker-snmp-sv2/snmpd.conf.j2 @@ -13,24 +13,9 @@ # AGENT BEHAVIOUR # -{% if MGMT_INTERFACE %} -# Listen for connections on localhost, loopback ip and mgmt (eth0) ip -agentAddress udp:127.0.0.1:161 -{% for (name, prefix) in MGMT_INTERFACE %} -{% if prefix | ipv4 %} -agentAddress udp:{{ prefix | ip }}:161 -{% endif %} -{% endfor %} -# TODO: only support ipv4 lo addresses, add ipv6 support later -{% for (name, prefix) in LOOPBACK_INTERFACE %} -{% if prefix | ipv4 %} -agentAddress udp:{{ prefix | ip }}:161 -{% endif %} -{% endfor %} -{% else %} -# Listen on all addresses as mgmt ip not specified +# Listen for connections on all ip addresses, including eth0, ipv4 lo agentAddress udp:161 -{% endif %} +# TODO: only support ipv4 lo addresses, add ipv6 support later ############################################################################### #