community.crypto.gpg_fingerprint (2.18.0) — lookup

Retrieve a GPG fingerprint from a GPG public or private key file

| "added in version" 2.15.0 of community.crypto"

Authors: Felix Fontein (@felixfontein)

Install collection

Install with ansible-galaxy collection install community.crypto:==2.18.0


Add to requirements.yml

  collections:
    - name: community.crypto
      version: 2.18.0

Description

Takes a list of filenames pointing to GPG public or private key files. Returns the fingerprints for each of these keys.


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Show fingerprint of GPG public key
  ansible.builtin.debug:
    msg: "{{ lookup('community.crypto.gpg_fingerprint', '/path/to/public_key.gpg') }}"

Inputs

    
_terms:
    description:
    - A path to a GPG public or private key.
    elements: path
    required: true
    type: list

Outputs

_value:
  description:
  - The fingerprints of the provided public or private GPG keys.
  - The list has one entry for every path provided.
  elements: string
  type: list

See also