pulp.squeezer.container_distribution (0.0.15) — module

Manage container distributions of a pulp api server instance

Authors: Mark Goddard (@markgoddard)

Install collection

Install with ansible-galaxy collection install pulp.squeezer:==0.0.15


Add to requirements.yml

  collections:
    - name: pulp.squeezer
      version: 0.0.15

Description

This performs CRUD operations on container distributions in a pulp api server instance.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Read list of container distributions
  pulp.squeezer.container_distribution:
    pulp_url: https://pulp.example.org
    username: admin
    password: password
  register: distribution_status
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Report pulp container distributions
  debug:
    var: distribution_status
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Create a container distribution
  pulp.squeezer.container_distribution:
    pulp_url: https://pulp.example.org
    username: admin
    password: password
    name: new_container_distribution
    base_path: new/container/dist
    repository: repository
    state: present
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Delete a container distribution
  pulp.squeezer.container_distribution:
    pulp_url: https://pulp.example.org
    username: admin
    password: password
    name: new_container_distribution
    state: absent

Inputs

    
name:
    description:
    - Name of the distribution to query or manipulate
    required: false
    type: str

state:
    choices:
    - present
    - absent
    description:
    - State the entity should be in
    type: str

private:
    description:
    - Whether to make the distribution private.
    required: false
    type: bool

timeout:
    default: 10
    description:
    - Time in seconds to wait for tasks.
    type: int

version:
    description:
    - Version number of the repository to be served
    - If not specified, the distribution will always serve the latest version.
    required: false
    type: int

password:
    description:
    - Password of api user.
    - If no value is specified, the value of the environment variable C(SQUEEZER_PASSWORD)
      will be used as a fallback.
    required: false
    type: str

pulp_url:
    description:
    - URL of the server to connect to (without 'pulp/api/v3').
    - If no value is specified, the value of the environment variable C(SQUEEZER_PULP_URL)
      will be used as a fallback.
    required: true
    type: str

user_key:
    description:
    - Client certificate key of api user.
    required: false
    type: str

username:
    description:
    - Username of api user.
    - If no value is specified, the value of the environment variable C(SQUEEZER_USERNAME)
      will be used as a fallback.
    required: false
    type: str

base_path:
    description:
    - Base path to distribute a repository
    required: false
    type: str

user_cert:
    description:
    - Client certificate of api user.
    required: false
    type: str

repository:
    description:
    - The latest RepositoryVersion for this Repository will be served.
    required: false
    type: str

content_guard:
    description:
    - Name of the content guard for the served content
    - 'Warning: This feature is not yet supported.'
    required: false
    type: str

validate_certs:
    default: true
    description:
    - Whether SSL certificates should be verified.
    - If no value is specified, the value of the environment variable C(SQUEEZER_VALIDATE_CERTS)
      will be used as a fallback.
    type: bool

refresh_api_cache:
    default: false
    description:
    - Whether the cached API specification should be invalidated.
    - It is recommended to use this once with the M(pulp.squeezer.status) module at the
      beginning of the playbook.
    type: bool

Outputs

distribution:
  description: Container distribution details
  returned: when name is given
  type: dict
distributions:
  description: List of container distributions
  returned: when no name is given
  type: list