theforeman.foreman.foreman_compute_attribute (0.8.1) — module

Manage Foreman Compute Attributes

Authors: Manisha Singhal (@Manisha15) ATIX AG

preview | supported by community

Install collection

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


Add to requirements.yml

  collections:
    - name: theforeman.foreman
      version: 0.8.1

Description

Manage Foreman Compute Attributes

This beta version can create, and update compute attributes


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: "Create compute attribute"
  foreman_compute_attribute:
    username: "admin"
    password: "changeme"
    server_url: "https://foreman.example.com"
    compute_profile: "Test Compute Profile"
    compute_resource: "Test Compute Resource"
    vm_attrs:
      memory_mb: '2048'
      cpu: '2'
    state: present
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: "Update compute attribute"
  foreman_compute_attribute:
    username: "admin"
    password: "changeme"
    server_url: "https://foreman.example.com"
    compute_profile: "Test Compute Profile"
    compute_resource: "Test Compute Resource"
    vm_attrs:
      memory_mb: '1024'
      cpu: '1'
    state: present

Inputs

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

password:
    description: Password of the user accessing the Foreman server
    required: true
    type: str

username:
    description: Username accessing the Foreman server
    required: true
    type: str

vm_attrs:
    aliases:
    - vm_attributes
    description:
    - Hash containing the data of vm_attrs
    required: false
    type: dict

server_url:
    description: URL of the Foreman server
    required: true
    type: str

validate_certs:
    aliases:
    - verify_ssl
    default: true
    description: Whether or not to verify the TLS certificates of the Foreman server
    type: bool

compute_profile:
    description:
    - Name of compute profile
    required: true
    type: str

compute_resource:
    description:
    - Name of compute resource
    required: true
    type: str