SNMP agent (NetSNMP) that can be configured at run time via environment variables.
181
SNMP agent (NetSNMP) that can be configured at run time via environment variables.
By default only the system group is accessible (read-only) using the version 2 of the protocol and the community public. You can define communities/users with read-only/read-write access to the whole MIB using the environment variables defined below.
Environment variables supported in current version of the container.
AGENT_ADDRESS: Address on which the agent will run. By default it will be 0.0.0.0 (all interfaces).
SYS_DESCR: A textual description of the entity as defined in 1.3.6.1.2.1.1.1
SYS_CONTACT: Name and contact information of the node manager as defined in 1.3.6.1.2.1.1.4
SYS_NAME: Name assigned to this node as defined in 1.3.6.1.2.1.1.5
SYS_LOCATION: The physical location of this node as defined in 1.3.6.1.2.1.1.6
RO_COMMUNITY: SNMPv1 or SNMPv2c community that will be allowed read-only access to the whole MIB.
RW_COMMUNITY: SNMPv1 or SNMPv2c community that will be allowed read-write access to the whole MIB.
RO_USER: SNMPv3 user that will be allowed read-only access to the whole MIB.
RO_PASS: passphrase used for both, authentication (SHA) and privacy (AES), for the read-only user. Warning: the minimum pass phrase length is 8 characters.
RW_USER: SNMPv3 user that will be allowed read-write access to the whole MIB.
RW_PASS: passphrase used for both, authentication (SHA) and privacy (AES), for the read-write user. Warning: the minimum pass phrase length is 8 characters.
In this section you will find some examples to launch the SNMP agent using configuration options defined above from different command line interpreters.
docker run -p 127.0.0.1:161:161/tcp \
--name netsnmp \
--env AGENT_ADDRESS=0.0.0.0 \
--env SYS_DESCR="A brief description of the agent." \
--env SYS_CONTACT="Agent owner [email protected]" \
--env SYS_NAME="Test agent." \
--env SYS_LOCATION="At home." \
--env RO_COMMUNITY=rocommunity \
--env RW_COMMUNITY=rwcommunity \
--env RO_USER=rouser \
--env RO_PASS=ABCDEFGHIJK \
--env RW_USER=rwuser \
--env RW_PASS=ABCDEFGHIJK \
jslarraz/netsnmp
docker run -p 127.0.0.1:161:161/tcp ^
--name netsnmp ^
--env AGENT_ADDRESS=0.0.0.0 ^
--env SYS_DESCR="A brief description of the agent." ^
--env SYS_CONTACT="Agent owner [email protected]" ^
--env SYS_NAME="Test agent." ^
--env SYS_LOCATION="At home." ^
--env RO_COMMUNITY=rocommunity ^
--env RW_COMMUNITY=rwcommunity ^
--env RO_USER=rouser ^
--env RO_PASS=ABCDEFGHIJK ^
--env RW_USER=rwuser ^
--env RW_PASS=ABCDEFGHIJK ^
jslarraz/netsnmp
docker run -p 127.0.0.1:161:161/tcp `
--name netsnmp `
--env AGENT_ADDRESS=0.0.0.0 `
--env SYS_DESCR="A brief description of the agent." `
--env SYS_CONTACT="Agent owner [email protected]" `
--env SYS_NAME="Test agent." `
--env SYS_LOCATION="At home." `
--env RO_COMMUNITY=rocommunity `
--env RW_COMMUNITY=rwcommunity `
--env RO_USER=rouser `
--env RO_PASS=ABCDEFGHIJK `
--env RW_USER=rwuser `
--env RW_PASS=ABCDEFGHIJK `
jslarraz/netsnmp
Content type
Image
Digest
sha256:616a3a7a3…
Size
104.1 MB
Last updated
over 3 years ago
docker pull jslarraz/netsnmp