fix unwanted format changes

seems like I had an older version of this module formatted differently or that I had a formatter that automatically ran on this file
This commit is contained in:
Ryan BADAÏ 2025-03-27 16:11:26 +01:00 committed by GitHub
parent 84fbc74422
commit 86edbaa734
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -9,14 +9,13 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type __metaclass__ = type
DOCUMENTATION = ''' DOCUMENTATION = r"""
---
module: hpilo_boot module: hpilo_boot
author: Dag Wieers (@dagwieers) author: Dag Wieers (@dagwieers)
short_description: Boot system using specific media through HP iLO interface short_description: Boot system using specific media through HP iLO interface
description: description:
- "This module boots a system through its HP iLO interface. The boot media - 'This module boots a system through its HP iLO interface. The boot media can be one of: V(cdrom), V(floppy), V(hdd), V(network),
can be one of: cdrom, floppy, hdd, network or usb." or V(usb).'
- This module requires the hpilo python module. - This module requires the hpilo python module.
extends_documentation_fragment: extends_documentation_fragment:
- community.general.attributes - community.general.attributes
@ -43,33 +42,32 @@ options:
type: str type: str
media: media:
description: description:
- The boot media to boot the system from - The boot media to boot the system from.
choices: [ "cdrom", "floppy", "rbsu", "hdd", "network", "normal", "usb" ] choices: ["cdrom", "floppy", "rbsu", "hdd", "network", "normal", "usb"]
type: str type: str
image: image:
description: description:
- The URL of a cdrom, floppy or usb boot media image. - The URL of a cdrom, floppy or usb boot media image in the form V(protocol://username:password@hostname:port/filename).
protocol://username:password@hostname:port/filename - V(protocol) is either V(http) or V(https).
- protocol is either 'http' or 'https' - V(username:password) is optional.
- username:password is optional - V(port) is optional.
- port is optional
type: str type: str
state: state:
description: description:
- The state of the boot media. - The state of the boot media.
- "no_boot: Do not boot from the device" - 'V(no_boot): Do not boot from the device.'
- "boot_once: Boot from the device once and then notthereafter" - 'V(boot_once): Boot from the device once and then notthereafter.'
- "boot_always: Boot from the device each time the server is rebooted" - 'V(boot_always): Boot from the device each time the server is rebooted.'
- "connect: Connect the virtual media device and set to boot_always" - 'V(connect): Connect the virtual media device and set to boot_always.'
- "disconnect: Disconnects the virtual media device and set to no_boot" - 'V(disconnect): Disconnects the virtual media device and set to no_boot.'
- "poweroff: Power off the server" - 'V(poweroff): Power off the server.'
default: boot_once default: boot_once
type: str type: str
choices: [ "boot_always", "boot_once", "connect", "disconnect", "no_boot", "poweroff" ] choices: ["boot_always", "boot_once", "connect", "disconnect", "no_boot", "poweroff"]
force: force:
description: description:
- Whether to force a reboot (even when the system is already booted). - Whether to force a reboot (even when the system is already booted).
- As a safeguard, without force, hpilo_boot will refuse to reboot a server that is already running. - As a safeguard, without force, hpilo_boot will refuse to reboot a server that is already running.
default: false default: false
type: bool type: bool
ssl_version: ssl_version:
@ -77,21 +75,21 @@ options:
- Change the ssl_version used. - Change the ssl_version used.
default: TLSv1 default: TLSv1
type: str type: str
choices: [ "SSLv3", "SSLv23", "TLSv1", "TLSv1_1", "TLSv1_2" ] choices: ["SSLv3", "SSLv23", "TLSv1", "TLSv1_1", "TLSv1_2"]
idempotent_boot_once: idempotent_boot_once:
description: description:
This makes the boot_once idempotent see github PR: https://github.com/ansible-collections/community.general/pull/9646 This makes the boot_once idempotent see github PR: https://github.com/ansible-collections/community.general/pull/9646
type: bool type: bool
default: false default: false
requirements: requirements:
- python-hpilo - python-hpilo
notes: notes:
- To use a USB key image you need to specify floppy as boot media. - To use a USB key image you need to specify floppy as boot media.
- This module ought to be run from a system that can access the HP iLO - This module ought to be run from a system that can access the HP iLO interface directly, either by using C(local_action)
interface directly, either by using C(local_action) or using C(delegate_to). or using C(delegate_to).
''' """
EXAMPLES = r''' EXAMPLES = r"""
- name: Task to boot a system using an ISO from an HP iLO interface only if the system is an HP server - name: Task to boot a system using an ISO from an HP iLO interface only if the system is an HP server
community.general.hpilo_boot: community.general.hpilo_boot:
host: YOUR_ILO_ADDRESS host: YOUR_ILO_ADDRESS
@ -109,11 +107,11 @@ EXAMPLES = r'''
password: YOUR_ILO_PASSWORD password: YOUR_ILO_PASSWORD
state: poweroff state: poweroff
delegate_to: localhost delegate_to: localhost
''' """
RETURN = ''' RETURN = r"""
# Default return values # Default return values
''' """
import time import time
import traceback import traceback