W3cubDocs

/Ansible 2.10

cloudscale_ch.cloud.objects_user – Manages objects users on the cloudscale.ch IaaS service

Note

This plugin is part of the cloudscale_ch.cloud collection.

To install it use: ansible-galaxy collection install cloudscale_ch.cloud.

To use it in a playbook, specify: cloudscale_ch.cloud.objects_user.

New in version 1.1.0: of cloudscale_ch.cloud

Synopsis

  • Create, update and remove objects users cloudscale.ch IaaS service.

Parameters

Parameter Choices/Defaults Comments
api_timeout
integer
Default:
30
Timeout in seconds for calls to the cloudscale.ch API.
api_token
string / required
cloudscale.ch API token.
This can also be passed in the CLOUDSCALE_API_TOKEN environment variable.
display_name
string
Display name of the objects user.
Either display_name or id is required.

aliases: name
id
string
Name of the objects user.
Either display_name or id is required.
state
string
    Choices:
  • present
  • absent
State of the objects user.
tags
dictionary
Tags associated with the objects user. Set this to {} to clear any tags.

Notes

Note

  • Instead of the api_token parameter the CLOUDSCALE_API_TOKEN environment variable can be used.
  • All operations are performed using the cloudscale.ch public API v1.
  • For details consult the full API documentation: https://www.cloudscale.ch/en/api/v1.
  • A valid API token is required for all operations. You can create as many tokens as you like using the cloudscale.ch control panel at https://control.cloudscale.ch.

Examples

- name: Create an objects user
  cloudscale_ch.cloud.objects_user:
    display_name: alan
    tags:
      project: luna
    api_token: xxxxxx
  register: object_user

- name: print keys
  debug:
    var: object_user.keys

- name: Update an objects user
  cloudscale_ch.cloud.objects_user:
    display_name: alan
    tags:
      project: gemini
    api_token: xxxxxx

- name: Remove an objects user
  cloudscale_ch.cloud.objects_user:
    display_name: alan
    state: absent
    api_token: xxxxxx

Return Values

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

Key Returned Description
display_name
string
success
The display name of the objects user.

Sample:
alan
href
string
success when state == present
The API URL to get details about this resource.

Sample:
https://api.cloudscale.ch/v1/objects-users/6fe39134bf4178747eebc429f82cfafdd08891d4279d0d899bc4012db1db6a15
id
string
success
The ID of the objects user.

Sample:
6fe39134bf4178747eebc429f82cfafdd08891d4279d0d899bc4012db1db6a15
keys
complex
success
List of key objects.

access_key
string
success
The access key.

Sample:
0ZTAIBKSGYBRHQ09G11W
secret_key
string
success
The secret key.

Sample:
bn2ufcwbIa0ARLc5CLRSlVaCfFxPHOpHmjKiH34T
state
string
success
The current status of the objects user.

Sample:
present
tags
dictionary
success
Tags assosiated with the objects user.

Sample:
{'project': 'my project'}


Authors

  • Rene Moser (@resmo)

© 2012–2018 Michael DeHaan
© 2018–2019 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.10/collections/cloudscale_ch/cloud/objects_user_module.html