m1yag1.globus.globus_gcs module – Manage Globus Connect Server v5 resources

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_gcs.

New in m1yag1.globus 1.0.0

Synopsis

  • Setup and configure GCS v5 endpoints

  • Manage storage gateways (POSIX, S3, etc.)

  • Create and manage mapped collections

  • Assign and manage collection roles

  • All operations run globus-connect-server CLI on target host

Parameters

Parameter

Comments

allowed_domains

list / elements=string

List of allowed authentication domains for the storage gateway

Default: ["globus.org", "globusid.org", "clients.auth.globus.org"]

collection_base_path

string

Base path within storage gateway (collection only)

Default: "/"

collection_id

string

Existing collection ID (for updates/role management)

contact_email

string

Contact email (endpoint only)

delete_protection

boolean

Whether to enable delete protection on the collection (collection only). Default is true to prevent accidental deletion in production. For testing, explicitly set to false to allow easy cleanup.

Choices:

  • false

  • true ← (default)

department

string

Department name (endpoint only)

deployment_key_path

string

Path to deployment-key.json file (endpoint only)

description

string

Description of the resource

display_name

string

Display name (endpoint, storage_gateway, collection)

endpoint_id

string

Endpoint ID (required for node setup and some operations)

force

boolean

Force update of resources even when no change is detected. For storage_gateway: Always update identity mapping if provided, even if gateway already exists. Default is false (idempotent behavior).

Choices:

  • false ← (default)

  • true

identity_mapping

any

Identity mapping configuration for the storage gateway

Can be a file path (string), a dict with full mapping structure, or a list of mapping rules

Example inline: [{source: ‘{username}’, match: ‘art’, output: ‘ubuntu’, literal: true}]

Example file: ‘/path/to/identity-mapping.json’

organization

string

Organization name (endpoint only)

owner

string

Endpoint owner identity (endpoint only)

principal

string

Principal URN for role assignment (role only)

project_id

string

Globus project ID (endpoint only)

public

boolean

Whether collection is public (collection only)

Choices:

  • false ← (default)

  • true

resource_type

string / required

Type of GCS resource to manage

Choices:

  • "endpoint"

  • "node"

  • "storage_gateway"

  • "collection"

  • "role"

role

string

Role to assign (role only)

Choices:

  • "administrator"

  • "access_manager"

  • "activity_manager"

  • "activity_monitor"

root_path

string

Root path for POSIX storage (storage_gateway only)

state

string

Desired state of the resource

Choices:

  • "present" ← (default)

  • "absent"

storage_gateway_id

string

ID of the storage gateway (collection only)

storage_type

string

Type of storage gateway

Choices:

  • "posix" ← (default)

  • "blackpearl"

  • "s3"

  • "google_cloud_storage"

  • "azure_blob"

subscription_id

string

GCS subscription ID (endpoint only). Note: If setting subscription_id during initial endpoint setup, the endpoint must be deployed (node setup completed) first. If the endpoint is not yet deployed, a warning will be shown but the task will not fail. Set subscription_id after node setup for best results.

Examples

# Setup GCS endpoint
- name: Setup GCS endpoint
  globus_gcs:
    resource_type: endpoint
    display_name: "My GCS Endpoint"
    organization: "University"
    contact_email: "admin@university.edu"
    project_id: "{{ project_id }}"
    subscription_id: "{{ subscription_id }}"
    state: present

# Create POSIX storage gateway
- name: Create POSIX storage gateway
  globus_gcs:
    resource_type: storage_gateway
    display_name: "My POSIX Gateway"
    storage_type: posix
    root_path: "/data"
    description: "Main data storage"
    state: present

# Create mapped collection
- name: Create mapped collection
  globus_gcs:
    resource_type: collection
    display_name: "My Collection"
    storage_gateway_id: "{{ gateway_id }}"
    collection_base_path: "/"
    description: "Research data collection"
    public: false
    state: present

# Assign administrator role
- name: Assign administrator role
  globus_gcs:
    resource_type: role
    collection_id: "{{ collection_id }}"
    principal: "urn:globus:auth:identity:12345"
    role: administrator
    state: present

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

changed

boolean

Whether the resource was changed

Returned: always

collection_id

string

ID of the collection

Returned: when resource_type=collection and state=present

endpoint_domain

string

Domain name of the endpoint

Returned: when resource_type=endpoint and state=present

endpoint_id

string

ID of the endpoint

Returned: when resource_type=endpoint and state=present

principal

string

Principal URN

Returned: when resource_type=role

role

string

Role assigned

Returned: when resource_type=role and state=present

storage_gateway_id

string

ID of the storage gateway

Returned: when resource_type=storage_gateway and state=present

Authors

  • m1yag1