joltcan / joltcan.op / 1.1.0 / lookup / lookup retreive information from vault(s) in 1Password via 1Password connect | "added in version" 1.1 of joltcan.op" Authors: Fredrik Lundhag (@joltcan)joltcan.op.lookup (1.1.0) — lookup
Install with ansible-galaxy collection install joltcan.op:==1.1.0
collections: - name: joltcan.op version: 1.1.0
Retreive information from vaults in 1Password via 1Password Connect (opconnect). An opconnect instance is needed, see https://github.com/1Password/connect
--- - hosts: 127.0.0.1 tasks: - set_fact: foo_password="{{ lookup('opconnect', 'item', vault='OPS', section='creds', field='api_key') }}" - debug: msg="var is {{ foo_password }} " - debug: msg="{{ lookup('opconnect', 'item', vault='OPS') }}" # will return the password value of the item.
field: description: field to search for. Needed when section is used required: false vault: description: Name of the vault that the item resides in. required: true _terms: description: Vault item too look for required: true section: description: Item section, can be used with field below. required: false op_connect_host_api: description: REST API endpoint for 1Password Connect env: - name: OP_CONNECT_HOST_API ini: - key: op_connect_host_api section: op_connect required: true type: string op_connect_token_api: description: API token for 1Password Connect access env: - name: OP_CONNECT_TOKEN_API ini: - key: op_connect_token_api section: op_connect required: true type: string op_connect_ca_bundle_api: description: Custom CA bundle for self signed certificates env: - name: OP_CONNECT_CA_BUNDLE_API ini: - key: op_connect_ca_bundle section: op_connect required: false type: boolean op_connect_skip_verify_api: description: Skip TLS host verification env: - name: OP_CONNECT_SKIP_VERIFY_API ini: - key: op_connect_skip_verify_api section: op_connect required: false type: boolean
_list: description: 1Password item value