community.hrobot.storagebox_snapshot_info module – Query the snapshots for a storage box
Note
This module is part of the community.hrobot collection (version 2.5.0).
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 community.hrobot
.
To use it in a playbook, specify: community.hrobot.storagebox_snapshot_info
.
New in community.hrobot 2.4.0
Synopsis
Query the snapshots for a storage box.
Parameters
Parameter |
Comments |
---|---|
The password for the Robot web-service user. If This option is deprecated for this module, and support will be removed in community.hrobot 3.0.0. |
|
The API token for the Robot web-service user. One of This option will be required from community.hrobot 3.0.0 on. |
|
The username for the Robot web-service user. One of If This option is deprecated for this module, and support will be removed in community.hrobot 3.0.0. |
|
Timeout (in seconds) for waiting when rate limit exceeded errors are returned. Set to Set to a negative value like Default: |
|
The ID of the storage box to query. |
Attributes
Attribute |
Support |
Description |
---|---|---|
Action groups: community.hrobot.api, community.hrobot.robot |
Use The |
|
Support: full This action does not modify state. |
Can run in |
|
Support: N/A This action does not modify state. |
Will return details on what has changed (or possibly needs changing in |
|
Support: full This action does not modify state. |
When run twice in a row outside check mode, with the same arguments, the second invocation indicates no change. This assumes that the system controlled/queried by the module has not changed in a relevant way. |
Examples
---
- name: Query the snapshots
community.hrobot.storagebox_snapshot_info:
hetzner_user: foo
hetzner_password: bar
id: 123
register: result
- name: Output data
ansible.builtin.debug:
msg: "Timestamp of the first snapshot : {{ result.snapshots[0].timestamp }}"
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
The storage box’s info. All date and time parameters are in UTC. Returned: success |
|
Whether the snapshot was created automatically. Note that this is computed from This return value is deprecated and will be removed from community.hrobot 3.0.0. If you are using ansible-core 2.19 or newer, you will see a deprecation message when using this return value. Returned: success Sample: |
|
The comment for the snapshot. Note that this is copied from This return value is deprecated and will be removed from community.hrobot 3.0.0. If you are using ansible-core 2.19 or newer, you will see a deprecation message when using this return value. Returned: success Sample: |
|
The creation timestamp of snapshot in UTC, in ISO-8601 format. Returned: success and Sample: |
|
The snapshot’s description (used to be called comment in the Robot API). Returned: success and Sample: |
|
The size of the Storage Box at creation time of the snapshot in MB. Note that this is computed from This return value is deprecated and will be removed from community.hrobot 3.0.0. If you are using ansible-core 2.19 or newer, you will see a deprecation message when using this return value. Returned: success Sample: |
|
Whether the snapshot was created automatically. Returned: success and Sample: |
|
User-defined labels for the snapshot. Returned: success and |
|
The snapshot name. Returned: success Sample: |
|
The Snapshot size in MB. Note that this is copied from This return value is deprecated and will be removed from community.hrobot 3.0.0. If you are using ansible-core 2.19 or newer, you will see a deprecation message when using this return value. Returned: success Sample: |
|
Statistics about the snapshot. Returned: success and |
|
Total size of the snapshot in bytes. Returned: success Sample: |
|
Actual size of the snapshot on the filesystem in bytes (after deduplication). Returned: success Sample: |
|
The timestamp of snapshot in UTC. Note that this is copied from This return value is deprecated and will be removed from community.hrobot 3.0.0. If you are using ansible-core 2.19 or newer, you will see a deprecation message when using this return value. Returned: success Sample: |