kembitnl.pmp.getcert (1.1.6) — module

Retrieve certificate and password

Authors: KEMBIT Automation team (ansible@kembit.nl)

Install collection

Install with ansible-galaxy collection install kembitnl.pmp:==1.1.6


Add to requirements.yml

  collections:
    - name: kembitnl.pmp
      version: 1.1.6

Description

Retrieves a certificate from a PMP keystore and saves it to a local file. If a password is registered in PMP, it is also retrieved.

The PMP URL and authtoken must be set in environment variables PMP_URL and PMP_AUTHTOKEN.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
# Retrieve a certificate
- name: Get certificate for webserver
  kembitnl.pmp.certificate:
    resourcename: 'Certificates'
    organization: CUSTOMER
    account: www.example.com

Inputs

    
orgName:
    aliases:
    - organization
    description: The name of the organization. If omitted, the default organization will
      be used.
    required: false
    type: str

accountname:
    description: The name of the certificate
    required: true
    type: str

resourcename:
    description: The name of the resource in Password Manager Pro where the certificate
      can be found.
    required: true
    type: str

Outputs

certificate:
  description: 'Returns an object with the filename, randomly generated in /tmp, which
    contains the certificate, and the password. B(WARNING): The password is returned
    as plain text, so always put a no_log: true statement in the block when calling
    this module!'
  returned: on success
  sample:
    certfile: /tmp/abcdefghijklmnopqrst
    password: TheverysecretPasswordoftheCert!
  type: dict