theforeman.foreman.architecture (4.0.0) — module

Manage Architectures

| "added in version" 1.0.0 of theforeman.foreman"

Authors: Manisha Singhal (@Manisha15) ATIX AG

Install collection

Install with ansible-galaxy collection install theforeman.foreman:==4.0.0


Add to requirements.yml

  collections:
    - name: theforeman.foreman
      version: 4.0.0

Description

Create, update, and delete Architectures


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: "Create an Architecture"
  theforeman.foreman.architecture:
    name: "i386"
    operatingsystems:
      - "TestOS1"
      - "TestOS2"
    server_url: "https://foreman.example.com"
    username: "admin"
    password: "changeme"
    state: present
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: "Update an Architecture"
  theforeman.foreman.architecture:
    name: "i386"
    operatingsystems:
      - "TestOS3"
      - "TestOS4"
    server_url: "https://foreman.example.com"
    username: "admin"
    password: "changeme"
    state: present
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: "Delete an Architecture"
  theforeman.foreman.architecture:
    name: "i386"
    server_url: "https://foreman.example.com"
    username: "admin"
    password: "changeme"
    state: absent

Inputs

    
name:
    description: Name of architecture
    required: true
    type: str

state:
    choices:
    - present
    - absent
    default: present
    description:
    - State of the entity
    type: str

password:
    description:
    - Password of the user accessing the Foreman server.
    - If the value is not specified in the task, the value of environment variable C(FOREMAN_PASSWORD)
      will be used instead.
    required: true
    type: str

username:
    description:
    - Username accessing the Foreman server.
    - If the value is not specified in the task, the value of environment variable C(FOREMAN_USERNAME)
      will be used instead.
    required: true
    type: str

server_url:
    description:
    - URL of the Foreman server.
    - If the value is not specified in the task, the value of environment variable C(FOREMAN_SERVER_URL)
      will be used instead.
    required: true
    type: str

updated_name:
    description: New architecture name. When this parameter is set, the module will not
      be idempotent.
    type: str

validate_certs:
    default: true
    description:
    - Whether or not to verify the TLS certificates of the Foreman server.
    - If the value is not specified in the task, the value of environment variable C(FOREMAN_VALIDATE_CERTS)
      will be used instead.
    type: bool

operatingsystems:
    description:
    - List of operating systems the entity should be assigned to.
    - Operating systems are looked up by their title which is composed as "<name> <major>.<minor>".
    - You can omit the version part as long as you only have one operating system by that
      name.
    elements: str
    required: false
    type: list

Outputs

entity:
  contains:
    architectures:
      contains:
        id:
          description: Database id of the architecture.
          type: int
        name:
          description: Name of the architecture.
          type: str
        operatinsystem_ids:
          description: Database ids of associated operatingsystems.
          elements: int
          type: list
      description: List of architectures.
      elements: dict
      type: list
  description: Final state of the affected entities grouped by their type.
  returned: success
  type: dict