elektra_initiative.libelektra.elektra (0.2.2) — module

libelektra interface

| "added in version" 2.8.6 of elektra_initiative.libelektra"

Authors: Thomas Waser

preview | supported by community

Install collection

Install with ansible-galaxy collection install elektra_initiative.libelektra:==0.2.2


Add to requirements.yml

  collections:
    - name: elektra_initiative.libelektra
      version: 0.2.2

Description

This module is used to manage configurations using libelektra

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
# mount /etc/hosts with recommends to system:/hosts and set localhost to 127.0.0.1
- name: update localhost ip
  elektra:
    mountpoint: system:/hosts
    filename: /etc/hosts
    recommends: True
    plugins:
        - hosts:
    keys:
        ipv4:
            localhost: 127.0.0.1
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
# mount /tmp/test.ini to system:/testini using the ini plugin and ':' as separator instead of '='
# and replace "key: value" with "key: newvalue"
- name: mount ini
  elektra:
      mountpoint: system:/testini
      filename: /tmp/test.ini
      plugins:
        - ini:
            delimiter: ':'
      keys:
        key: newvalue

Inputs

    
keys:
    description:
    - keyset to write
    required: false

plugins:
    description:
    - list of plugins to be used as backend and their configuration
    required: true

filename:
    description:
    - name of the configuration that to be mounted
    required: false

resolver:
    description:
    - which resolver should be used for the backend
    required: false

keeporder:
    description:
    - use "order" metadata to preserve the order of the passed keyset

mountpoint:
    description:
    - mountpoint of the configuration
    required: true

recommends:
    description:
    - use recommended plugins
    required: false