community.general.shelvefile (0.2.1) — lookup

read keys from Python shelve file

Authors: Alejandro Guirao <lekumberri@gmail.com>

Install collection

Install with ansible-galaxy collection install community.general:==0.2.1


Add to requirements.yml

  collections:
    - name: community.general
      version: 0.2.1

Description

Read keys from Python shelve file.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: retrieve a string value corresponding to a key inside a Python shelve file
  debug: msg="{{ lookup('shelvefile', 'file=path_to_some_shelve_file.db key=key_to_retrieve') }}

Inputs

    
key:
    description: key to query
    required: true

file:
    description: path to shelve file
    required: true

_terms:
    description: sets of key value pairs of parameters

Outputs

_list:
  description: value(s) of key(s) in shelve file(s)