statusio_maintenance - Create maintenance windows for your status.io dashboard

New in version 2.2.

Synopsis

Parameters

Parameter Choices/Defaults Comments
all_infrastructure_affected
bool
    Choices:
  • no ←
  • yes
If it affects all components and containers
api_id
required
Your unique API ID from status.io
api_key
required
Your unique API Key from status.io
automation
bool
    Choices:
  • no ←
  • yes
Automatically start and end the maintenance window
components
The given name of your component (server name)

aliases: component
containers
The given name of your container (data center)

aliases: container
desc Default:
Created by Ansible
Message describing the maintenance window
maintenance_id
The maintenance id number when deleting a maintenance window
maintenance_notify_1_hr
bool
    Choices:
  • no ←
  • yes
Notify subscribers 1 hour before maintenance start time
maintenance_notify_24_hr
bool
    Choices:
  • no ←
  • yes
Notify subscribers 24 hours before maintenance start time
maintenance_notify_72_hr
bool
    Choices:
  • no ←
  • yes
Notify subscribers 72 hours before maintenance start time
maintenance_notify_now
bool
    Choices:
  • no ←
  • yes
Notify subscribers now
minutes Default:
10
The length of time in UTC that the maintenance will run (starting from playbook runtime)
start_date
Date maintenance is expected to start (Month/Day/Year) (UTC)
End Date is worked out from start_date + minutes
start_time
Time maintenance is expected to start (Hour:Minutes) (UTC)
End Time is worked out from start_time + minutes
state
    Choices:
  • present ←
  • absent
Desired state of the package.
statuspage
required
Your unique StatusPage ID from status.io
title Default:
A new maintenance window
A descriptive title for the maintenance window
url Default:
https://api.status.io
Status.io API URL. A private apiary can be used instead.

Notes

Note

  • You can use the apiary API url (http://docs.statusio.apiary.io/) to capture API traffic
  • Use start_date and start_time with minutes to set future maintenance window

Examples

- name: Create a maintenance window for 10 minutes on server1, with automation to stop the maintenance
  statusio_maintenance:
    title: Router Upgrade from ansible
    desc: Performing a Router Upgrade
    components: server1.example.com
    api_id: api_id
    api_key: api_key
    statuspage: statuspage_id
    maintenance_notify_1_hr: True
    automation: True

- name: Create a maintenance window for 60 minutes on server1 and server2
  statusio_maintenance:
    title: Routine maintenance
    desc: Some security updates
    components:
      - server1.example.com
      - server2.example.com
    minutes: 60
    api_id: api_id
    api_key: api_key
    statuspage: statuspage_id
    maintenance_notify_1_hr: True
    automation: True
  delegate_to: localhost

- name: Create a future maintenance window for 24 hours to all hosts inside the Primary Data Center
  statusio_maintenance:
    title: Data center downtime
    desc: Performing a Upgrade to our data center
    components: Primary Data Center
    api_id: api_id
    api_key: api_key
    statuspage: statuspage_id
    start_date: 01/01/2016
    start_time: 12:00
    minutes: 1440

- name: Delete a maintenance window
  statusio_maintenance:
    title: Remove a maintenance window
    maintenance_id: 561f90faf74bc94a4700087b
    statuspage: statuspage_id
    api_id: api_id
    api_key: api_key
    state: absent

Status

This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.

Maintenance

This module is flagged as community which means that it is maintained by the Ansible Community. See Module Maintenance & Support for more info.

For a list of other modules that are also maintained by the Ansible Community, see here.

Author

Hint

If you notice any issues in this documentation you can edit this document to improve it.