rarrais.borgwarehouse.repository (1.0.2) — module

Module for managing repositories in BorgWarehouse.

| "added in version" 1.0.2 of rarrais.borgwarehouse"

Authors: Rafael Arrais (@rarrais)

Install collection

Install with ansible-galaxy collection install rarrais.borgwarehouse:==1.0.2


Add to requirements.yml

  collections:
    - name: rarrais.borgwarehouse
      version: 1.0.2

Description

Module for managing repositories in BorgWarehouse.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Configure repository in BorgWarehouse.
  rarrais.borgwarehouse.repository:
    url: http://borgwarehouse.lan:3000
    api_token: yet-another-secret
    alias: ansibletest
    ssh_public_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIK0wmN/Cr3JXqmLW7u+g9pTh+wyqDHpSQEIQczXkVx9q ansibletest"

Inputs

    
url:
    description: BorgWarehouse URL in the format http://<fqdn>:(<port>).
    required: true
    type: str

size:
    default: 10
    description: Repository storage size in GB.
    required: false
    type: int

alert:
    default: 172800
    description: Repository backup alert in seconds.
    required: false
    type: int

alias:
    description: Repository name.
    required: true
    type: str

state:
    choices:
    - absent
    - present
    default: present
    description: Repository state.
    required: false
    type: str

comment:
    default: Managed by Ansible.
    description: Repository backup alert in seconds.
    required: false
    type: str

api_token:
    description: BorgBase API_TOKEN.
    required: true
    type: str

ssh_public_key:
    description: Repository SSH publick key.
    required: true
    type: str

Outputs

repository:
  description: Repository dictionary.
  returned: always
  sample:
    alert: 172800
    alias: ansibletest
    comment: Managed by Ansible.
    displayDetails: true
    id: 1
    lanCommand: false
    lastSave: 0
    repositoryName: e58c6bdf
    sshPublicKey: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIK0wmN/Cr3JXqmLW7u+g9pTh+wyqDHpSQEIQczXkVx9q
      ansibletest
    status: false
    storageSize: 10
    storageUsed: 0
  type: dict