ansible.builtin.shelvefile (v2.9.27) — lookup

read keys from Python shelve file

| "added in version" 2.0 of ansible.builtin"

Authors: Alejandro Guirao <lekumberri@gmail.com>

Install Ansible via pip

Install with pip install ansible==2.9.27

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)