salt.modules.win_powercfg

This module allows you to control the power settings of a windows minion via powercfg.

New in version 2015.8.0.

salt '*' powercfg.set_monitor_timeout 0 power=dc
salt '*' powercfg.set_disk_timeout 120 power=ac
salt.modules.win_powercfg.get_disk_timeout(scheme=None)

Get the current disk timeout of the given scheme

CLI Example:

salt '*' powercfg.get_disk_timeout
scheme
The scheme to use, leave as None to use the current.
salt.modules.win_powercfg.get_hibernate_timeout(scheme=None)

Get the current hibernate timeout of the given scheme

CLI Example:

salt '*' powercfg.get_hibernate_timeout
scheme
The scheme to use, leave as None to use the current.
salt.modules.win_powercfg.get_monitor_timeout(scheme=None)

Get the current monitor timeout of the given scheme

CLI Example:

salt '*' powercfg.get_monitor_timeout
scheme
The scheme to use, leave as None to use the current.
salt.modules.win_powercfg.get_standby_timeout(scheme=None)

Get the current standby timeout of the given scheme

CLI Example:

salt '*' powercfg.get_standby_timeout
scheme
The scheme to use, leave as None to use the current.
salt.modules.win_powercfg.set_disk_timeout(timeout, power='ac', scheme=None)

Set the disk timeout in minutes for the given power scheme

CLI Example:

salt '*' powercfg.set_disk_timeout 30 power=dc
timeout
The amount of time in minutes before the disk will timeout
power
Should we set the value for AC or DC (battery)? Valid options ac,dc.
scheme
The scheme to use, leave as None to use the current.
salt.modules.win_powercfg.set_hibernate_timeout(timeout, power='ac', scheme=None)

Set the hibernate timeout in minutes for the given power scheme

CLI Example:

salt '*' powercfg.set_hibernate_timeout 30 power=pc
timeout
The amount of time in minutes before the computer hibernates
power
Should we set the value for AC or DC (battery)? Valid options ac,dc.
scheme
The scheme to use, leave as None to use the current.
salt.modules.win_powercfg.set_monitor_timeout(timeout, power='ac', scheme=None)

Set the monitor timeout in minutes for the given power scheme

CLI Example:

salt '*' powercfg.set_monitor_timeout 30 power=ac
timeout
The amount of time in minutes before the monitor will timeout
power
Should we set the value for AC or DC (battery)? Valid options ac,dc.
scheme
The scheme to use, leave as None to use the current.
salt.modules.win_powercfg.set_standby_timeout(timeout, power='ac', scheme=None)

Set the standby timeout in minutes for the given power scheme

CLI Example:

salt '*' powercfg.set_standby_timeout 30 power=dc
timeout
The amount of time in minutes before the computer sleeps
power
Should we set the value for AC or DC (battery)? Valid options ac,dc.
scheme
The scheme to use, leave as None to use the current.