m1yag1.globus.globus_timer module – Manage Globus Timers
Note
This module is part of the m1yag1.globus collection (version 0.6.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 m1yag1.globus.
To use it in a playbook, specify: m1yag1.globus.globus_timer.
New in m1yag1.globus 1.0.0
Synopsis
Create, update, or delete Globus Timers
Schedule automated transfers and workflows
Supports both one-time and recurring timers
Parameters
Parameter |
Comments |
|---|---|
Authentication method to use. If not specified, auto-detects based on available credentials. When Otherwise falls back to Choices:
|
|
JSON body to send to callback URL |
|
URL to call when timer fires |
|
Globus Auth client ID for client_credentials authentication. Can also be set via the |
|
Globus Auth client secret for client_credentials authentication. Can also be set via the |
|
Name/label for the timer |
|
Schedule specification for the timer |
|
ISO 8601 datetime for one-time execution |
|
Interval in days for recurring timers |
|
Interval in hours for recurring timers |
|
Interval in minutes for recurring timers |
|
Interval in seconds for recurring timers |
|
Type of schedule (once, recurring) Choices:
|
|
Scope required for timer operation |
|
Start datetime (ISO 8601) for recurring timers |
|
Desired state of the timer Choices:
|
|
Stop datetime (ISO 8601) for recurring timers |
|
Number of executions before stopping |
|
ID of existing timer (for updates/deletion) |
Notes
Note
Authentication is required for all Globus API operations.
For
client_credentialsauth, register a confidential client at https://developers.globus.org.For
cliauth, runglobus loginfirst to cache tokens.The
climethod reads tokens from~/.globus/cli/storage.db.For
cliauth with multiple profiles, setGLOBUS_PROFILEenvironment variable.Set
GLOBUS_SDK_ENVIRONMENTtosandboxortestfor non-production environments.
See Also
See also
- Globus Auth Documentation
Official Globus authentication documentation
- Globus CLI
Command-line interface for Globus
Examples
- name: Create one-time timer
globus_timer:
name: "One-time data transfer"
schedule:
type: once
datetime: "2025-12-31T23:59:59Z"
callback_url: "https://transfer.api.globus.org/v0.10/transfer"
callback_body:
source_endpoint: "{{ source_ep }}"
destination_endpoint: "{{ dest_ep }}"
DATA:
- source_path: "/data/"
destination_path: "/backup/"
recursive: true
state: present
- name: Create recurring timer (every 24 hours)
globus_timer:
name: "Daily backup"
schedule:
type: recurring
interval_hours: 24
start: "2025-01-01T00:00:00Z"
callback_url: "https://transfer.api.globus.org/v0.10/transfer"
callback_body:
source_endpoint: "{{ source_ep }}"
destination_endpoint: "{{ dest_ep }}"
DATA:
- source_path: "/data/"
destination_path: "/backup/"
recursive: true
state: present
- name: Create timer with stop conditions
globus_timer:
name: "Weekly sync (10 times)"
schedule:
type: recurring
interval_days: 7
start: "2025-01-01T00:00:00Z"
stop_after_n: 10
callback_url: "https://transfer.api.globus.org/v0.10/transfer"
callback_body:
source_endpoint: "{{ source_ep }}"
destination_endpoint: "{{ dest_ep }}"
DATA:
- source_path: "/data/"
destination_path: "/sync/"
recursive: true
state: present
- name: Pause a timer
globus_timer:
name: "Daily backup"
state: inactive
- name: Resume a timer
globus_timer:
name: "Daily backup"
state: active
- name: Delete a timer
globus_timer:
name: "Old timer"
state: absent
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
|---|---|
Whether the timer was changed Returned: always |
|
Name of the timer Returned: always |
|
Timer schedule information Returned: when state=present |
|
Current status of the timer (active/inactive) Returned: when state=present |
|
ID of the created/managed timer Returned: when state=present |