Skip to content
Snippets Groups Projects
argument_specs.yml 5.5 KiB
Newer Older
Chris Croome's avatar
Chris Croome committed
# Copyright 2025 Chris Croome
#
# This file is part of the Webarchitects Valkey Ansible role.
#
# The Webarchitects Valkey Ansible role is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
#
# The Webarchitects Valkey Ansible role is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along with the Webarchitects Valkey Ansible role. If not, see <https://www.gnu.org/licenses/>.
---
argument_specs:
  main:
    author: Chris Croome
    description: Ansible role for installing and configuring nftables on Debian.
    short_description: The main entry point for the Valkey role.
    options:
      valkey:
        type: bool
        required: true
        description: Run the tasks in this role.
Chris Croome's avatar
Chris Croome committed
      valkey_apt_backports:
        type: str
        required: true
        description: String that will be present in the apt cache policy when backports are enabled.
Chris Croome's avatar
Chris Croome committed
      valkey_instances:
Chris Croome's avatar
Chris Croome committed
        type: list
Chris Croome's avatar
Chris Croome committed
        elements: dict
        required: true
        description: A list of Valkey instances and their configuration.
Chris Croome's avatar
Chris Croome committed
        options:
          name:
            type: str
            required: true
Chris Croome's avatar
Chris Croome committed
            description: The Valkey instance name.
          config:
            type: dict
            required: false
            description: A dictionary of keys and values for the Valkey configuration.
            options:
              bind:
                type: str
                required: false
                description: One or more IP addresses that the instance should bind to, each address can be prefixed by "-", which means that the server will not fail to start if the address is not available.
              port:
                type: int
                required: false
                description: Accept connections on the specified port, default is 6379. If port 0 is specified the server will not listen on a TCP socket.
              unixsocket:
                type: str
                required: false
                description: The path for the Unix socket that will be used to listen for incoming connections. There is no default, so the server will not listen on a unix socket when not specified.
              unixsocketperm:
                type: int
                required: false
                description: The Unix socket octal permissions, default 700.
              dbfilename:
                type: str
                required: false
                description: The filename where to dump the DB.
              logfile:
                type: str
                required: false
                description: The log file path.
              pidfile:
                type: str
                required: false
                description: Path to the pid file.
Chris Croome's avatar
Chris Croome committed
              requirepass:
                type: str
                required: false
                description: The instance default password.
Chris Croome's avatar
Chris Croome committed
          config_file:
Chris Croome's avatar
Chris Croome committed
            type: str
            required: true
Chris Croome's avatar
Chris Croome committed
            description: The path to the valkey instance configuration file.
          state:
            type: str
            required: true
            choices:
              - absent
              - enabled
            description: The state of the Valkey instance.
Chris Croome's avatar
Chris Croome committed
      valkey_enabled:
        type: bool
        required: true
        description: Enable and start Valkey.
Chris Croome's avatar
Chris Croome committed
      valkey_jpq:
        type: dict
        required: true
        description: A dictionary of JMESPath query strings.
        options:
          pkgs_absent:
            type: str
            required: true
            description: JMESPath query string for the packages absent.
          pkgs_present:
            type: str
            required: true
            description: JMESPath query string for the packages present.
          pkgs_present_backports:
            type: str
            required: true
            description: JMESPath query string for the backports packages present.
          service:
            type: str
            required: true
            description: JMESPath query string for the Valkey service.
Chris Croome's avatar
Chris Croome committed
      valkey_pkgs:
        type: list
        elements: dict
        required: true
        description: A list of distros and deb packages that should be absent and present.
        options:
          name:
            type: str
            required: true
            description: The Linux distro name.
            choices:
              - bookworm
              - noble
              - trixie
          pkgs_absent:
            type: list
            required: false
            description: A list of deb packages that should be absent.
          pkgs_present:
            type: list
            required: false
            description: A list of deb packages that should be present.
          pkgs_present_backports:
            type: list
Chris Croome's avatar
Chris Croome committed
            required: true
Chris Croome's avatar
Chris Croome committed
            description: A list of deb packages that should be present from backports.
Chris Croome's avatar
Chris Croome committed
      valkey_protected_configs:
        type: list
        required: false
        description: A list of Valkey config to be editing using lineinfile.
Chris Croome's avatar
Chris Croome committed
      valkey_verify:
        type: bool
        required: true
        description: Use the argument specification to verify the variables that start with valkey_.
Chris Croome's avatar
Chris Croome committed
...