-
Notifications
You must be signed in to change notification settings - Fork 19
monitor
Note
This module is part of the lucasheld.uptime_kuma collection (version 1.2.0).
You might already have this collection installed if you are using the ansible
package.
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install lucasheld.uptime_kuma
.
To use it in a playbook, specify: lucasheld.uptime_kuma.monitor
.
- Manages monitors.
The below requirements are needed on the host that executes this module.
- uptime-kuma-api
Parameter |
Comments |
---|---|
The accepted status codes of the monitor. |
|
Headers that are passed to the socketio connection. |
|
The Uptime Kuma password. Only required if no api_token specified and authentication is enabled. |
|
true to verify SSL certificates, or false to skip SSL certificate verification, allowing connections to servers with self signed certificates. Choices:
|
|
How many seconds the client should wait for the connection, an expected event or a server response. Default: 10 |
|
The Uptime Kuma login token. Only required if no api_username and api_password specified and authentication is enabled. |
|
The Uptime Kuma URL. Default: "http://127.0.0.1:3001" |
|
The Uptime Kuma username. Only required if no api_token specified and authentication is enabled. |
|
How many seconds the client should wait for the next event of the same type. There is no way to determine when the last message of a certain type has arrived. Therefore, a timeout is required. If no further message has arrived within this time, it is assumed that it was the last message. Default: 0.2 |
|
The auth domain of the monitor. |
|
The auth method of the monitor. Choices:
|
|
The auth workstation of the monitor. |
|
The auth pass of the monitor. |
|
The auth user of the monitor. |
|
The http body of the monitor. |
|
The sqlserver connection string of the monitor. |
|
The sqlserver query of the monitor. |
|
The description of the monitor. |
|
The dns resolve server of the monitor. |
|
The dns resolve type of the monitor. |
|
The docker container of the monitor. |
|
The docker host id of the monitor. Only required if no docker_host_name specified. |
|
The docker host name of the monitor. Only required if no docker_host specified. |
|
Expected Value |
|
True if certificate expiry notification is enabled. Choices:
|
|
The game of the monitor. |
|
Guess Gamedig Port. The port used by Valve Server Query Protocol may be different from the client port. Try this if the monitor cannot connect to your server. Choices:
|
|
The grpc body of the monitor. |
|
True to enable grpc tls. Choices:
|
|
The grpc metadata of the monitor. |
|
The grpc method of the monitor. |
|
The grpc protobuf of the monitor. |
|
The grpc service name of the monitor. |
|
The grpc url of the monitor. |
|
The http headers of the monitor. |
|
The hostname of the monitor. |
|
The body encoding of the monitor. |
|
The id of the monitor. Only required if no name specified. |
|
True if ignore tls error is enabled. Choices:
|
|
The heartbeat interval of the monitor. |
|
Invert Keyword. Look for the keyword to be absent rather than present. Choices:
|
|
Json Query |
|
Enable Kafka Producer Auto Topic Creation Choices:
|
|
Kafka Broker list |
|
Kafka Producer Message |
|
Kafka SASL Options |
|
Enable Kafka SSL Choices:
|
|
Kafka Topic Name |
|
The keyword of the monitor. |
|
The redirects of the monitor. |
|
The max retries of the monitor. |
|
The http method of the monitor. |
|
The mqtt password of the monitor. |
|
The mqtt success message of the monitor. |
|
The mqtt topic of the monitor. |
|
The mqtt username of the monitor. |
|
The name of the monitor. Only required if no id specified. |
|
The notification names of the monitor. Only required if notificationIDList not specified. |
|
The notification ids of the monitor. Only required if notification_names not specified. |
|
Authentication Method |
|
Client ID |
|
Client Secret |
|
OAuth Scope |
|
OAuth Token URL |
|
The packet size of the monitor. |
|
Id of the parent monitor. Only required if no parent_name specified. |
|
Name of the parent monitor. Only required if no parent specified. |
|
The port of the monitor. |
|
The proxy of the monitor. Only required if no proxyId specified. |
|
The host of the proxy. Only required if no proxyId specified. |
|
The port of the proxy. Only required if no proxyId specified. |
|
The proxy id of the monitor. Only required if no proxy specified. |
|
The radius called station id of the monitor. |
|
The radius calling station id of the monitor. |
|
The radius password of the monitor. |
|
The radius secret of the monitor. |
|
The radius username of the monitor. |
|
The heartbeat resend interval of the monitor. |
|
The heartbeat retry interval of the monitor. |
|
Set to Set to Set to Set to Choices:
|
|
Request Timeout |
|
The tls ca of the monitor. |
|
The tls cert of the monitor. |
|
The tls key of the monitor. |
|
The type of the monitor. Choices:
|
|
True if upside down mode is enabled. Choices:
|
|
The url of the monitor. |
- name: Add a monitor
lucasheld.uptime_kuma.monitor:
api_url: http://127.0.0.1:3001
api_username: admin
api_password: secret123
type: keyword
name: Monitor 1
url: http://127.0.0.1
keyword: healthy
state: present
- name: Edit a monitor
lucasheld.uptime_kuma.monitor:
api_url: http://127.0.0.1:3001
api_username: admin
api_password: secret123
type: http
name: Monitor 1
url: http://127.0.0.1
state: present
- name: Remove a monitor
lucasheld.uptime_kuma.monitor:
api_url: http://127.0.0.1:3001
api_username: admin
api_password: secret123
name: Monitor 1
state: absent
- name: Pause a monitor
lucasheld.uptime_kuma.monitor:
api_url: http://127.0.0.1:3001
api_username: admin
api_password: secret123
name: Monitor 1
state: paused
- name: Resume a monitor
lucasheld.uptime_kuma.monitor:
api_url: http://127.0.0.1:3001
api_username: admin
api_password: secret123
name: Monitor 1
state: resumed
- Lucas Held (@lucasheld)