Registry

registry

This is a module that supports creating, updating or destroying Registries

Example Syntax


name: Create Registry
ionoscloudsdk.ionoscloud.registry:
  name: 'ansibletest123-'
  location: de/fra
  garbage_collection_schedule:
    days:
    - Wednesday
    time: 04:17:00+00:00
  features:
    vulnerability_scanning:
      enabled: true
  wait: true
register: registry_response


name: Update Registry
ionoscloudsdk.ionoscloud.registry:
  registry: ''
  garbage_collection_schedule:
    days:
    - Wednesday
    - Sunday
    time: 06:17:00+00:00
  features:
    vulnerability_scanning:
      enabled: true
  allow_replace: false
  state: update
register: updated_registry_response


name: Delete Registry
ionoscloudsdk.ionoscloud.registry:
  registry: ''
  wait: true
  state: absent

Returned object

{
    "changed": true,
    "failed": false,
    "action": "create",
    "registry": {
        "href": "",
        "id": "9bc72c7b-14d3-493e-a700-f9bc06b25614",
        "metadata": {
            "created_by": "<USER_EMAIL>",
            "created_by_user_id": "<USER_ID>",
            "created_date": "2023-05-29T13:51:25+00:00",
            "last_modified_by": null,
            "last_modified_by_user_id": null,
            "last_modified_date": null,
            "state": "New"
        },
        "properties": {
            "garbage_collection_schedule": {
                "days": [
                    "Wednesday"
                ],
                "time": "04:17:00+00:00"
            },
            "hostname": "",
            "location": "de/fra",
            "name": "ansibletest123",
            "storage_usage": {
                "bytes": 0,
                "updated_at": null
            }
        },
        "type": "registry"
    }
}

For more examples please check out the tests here.

NOTE: If you are using a versions 7.0.0 and up: modules can replace resources if certain set parameters differ from the results found in the API!

Parameters that can trigger a resource replacement:

  • name

  • location

  • features (changing features.vulnerability_scanning.enabled from true to false will trigger a resource replacement)

state: present

  
name: Create Registry
ionoscloudsdk.ionoscloud.registry:
  name: 'ansibletest123-'
  location: de/fra
  garbage_collection_schedule:
    days:
    - Wednesday
    time: 04:17:00+00:00
  features:
    vulnerability_scanning:
      enabled: true
  wait: true
register: registry_response

Available parameters for state present:

state: absent

  
name: Delete Registry
ionoscloudsdk.ionoscloud.registry:
  registry: ''
  wait: true
  state: absent

Available parameters for state absent:

state: update

  
name: Update Registry
ionoscloudsdk.ionoscloud.registry:
  registry: ''
  garbage_collection_schedule:
    days:
    - Wednesday
    - Sunday
    time: 06:17:00+00:00
  features:
    vulnerability_scanning:
      enabled: true
  allow_replace: false
  state: update
register: updated_registry_response

Available parameters for state update:

Last updated