Server IP : 85.214.239.14 / Your IP : 18.223.108.134 Web Server : Apache/2.4.62 (Debian) System : Linux h2886529.stratoserver.net 4.9.0 #1 SMP Tue Jan 9 19:45:01 MSK 2024 x86_64 User : www-data ( 33) PHP Version : 7.4.18 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, MySQL : OFF | cURL : OFF | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : OFF Directory : /lib/python3/dist-packages/ansible_collections/community/windows/plugins/modules/ |
Upload File : |
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2018, Ansible, inc # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) DOCUMENTATION = r''' --- module: win_snmp short_description: Configures the Windows SNMP service description: - This module configures the Windows SNMP service. options: permitted_managers: description: - The list of permitted SNMP managers. type: list elements: str community_strings: description: - The list of read-only SNMP community strings. type: list elements: str action: description: - C(add) will add new SNMP community strings and/or SNMP managers - C(set) will replace SNMP community strings and/or SNMP managers. An empty list for either C(community_strings) or C(permitted_managers) will result in the respective lists being removed entirely. - C(remove) will remove SNMP community strings and/or SNMP managers type: str choices: [ add, set, remove ] default: set author: - Michael Cassaniti (@mcassaniti) ''' EXAMPLES = r''' - name: Replace SNMP communities and managers community.windows.win_snmp: community_strings: - public permitted_managers: - 192.168.1.2 action: set - name: Replace SNMP communities and clear managers community.windows.win_snmp: community_strings: - public permitted_managers: [] action: set ''' RETURN = r''' community_strings: description: The list of community strings for this machine. type: list returned: always sample: - public - snmp-ro permitted_managers: description: The list of permitted managers for this machine. type: list returned: always sample: - 192.168.1.1 - 192.168.1.2 '''