Debian Codegraph @

ansible_collections/community/windows/plugins/modules/win_wakeonlan.py

raw
1 #!/usr/bin/python
2 # -*- coding: utf-8 -*-
3
4 # Copyright: (c) 2017, Dag Wieers <[email protected]>
5 # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
6
7 DOCUMENTATION = r'''
8 ---
9 module: win_wakeonlan
10 short_description: Send a magic Wake-on-LAN (WoL) broadcast packet
11 description:
12 - The C(win_wakeonlan) module sends magic Wake-on-LAN (WoL) broadcast packets.
13 - For non-Windows targets, use the M(community.general.wakeonlan) module instead.
14 options:
15 mac:
16 description:
17 - MAC address to send Wake-on-LAN broadcast packet for.
18 type: str
19 required: yes
20 broadcast:
21 description:
22 - Network broadcast address to use for broadcasting magic Wake-on-LAN packet.
23 type: str
24 default: 255.255.255.255
25 port:
26 description:
27 - UDP port to use for magic Wake-on-LAN packet.
28 type: int
29 default: 7
30 todo:
31 - Does not have SecureOn password support
32 notes:
33 - This module sends a magic packet, without knowing whether it worked. It always report a change.
34 - Only works if the target system was properly configured for Wake-on-LAN (in the BIOS and/or the OS).
35 - Some BIOSes have a different (configurable) Wake-on-LAN boot order (i.e. PXE first).
36 seealso:
37 - module: community.general.wakeonlan
38 author:
39 - Dag Wieers (@dagwieers)
40 '''
41
42 EXAMPLES = r'''
43 - name: Send a magic Wake-on-LAN packet to 00:00:5E:00:53:66
44 community.windows.win_wakeonlan:
45 mac: 00:00:5E:00:53:66
46 broadcast: 192.0.2.23
47
48 - name: Send a magic Wake-On-LAN packet on port 9 to 00-00-5E-00-53-66
49 community.windows.win_wakeonlan:
50 mac: 00-00-5E-00-53-66
51 port: 9
52 delegate_to: remote_system
53 '''
54
55 RETURN = r'''
56 # Default return values
57 '''