Add Manjaro support (by @verbumfeit), CI fixes. (#65)

Co-authored-by: verbumfeit <verbumfeit@tuta.io>
This commit is contained in:
Manu 2021-04-20 14:53:35 +08:00 committed by GitHub
parent 7925d31198
commit 3bd0b3d497
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 30 additions and 21 deletions

View File

@ -12,10 +12,10 @@ jobs:
with:
python-version: 3.7
- name: Install Molecule
run: pip install molecule[lint,docker]
- name: Lint
run: |
yamllint .
ansible-lint
pip install -U pip setuptools wheel
pip install -r requirements-dev.txt
# - name: Debugging with tmate
# uses: mxschmitt/action-tmate@v3.5
- name: Test using Molecule
run: molecule test

View File

@ -1,5 +1,8 @@
---
# Based on ansible-lint config
ignore: |
.direnv
extends: default
rules:

View File

@ -17,7 +17,7 @@ Main features:
```
- hosts: webservers
roles:
- role: borgbackup
- role: m3nu.ansible_role_borgbackup
borg_encryption_passphrase: CHANGEME
borg_repository: m5vz9gp4@m5vz9gp4.repo.borgbase.com:repo
borg_source_directories:
@ -44,7 +44,7 @@ $ ansible-galaxy install m3nu.ansible_role_borgbackup
Clone to local folder
```
$ git clone https://github.com/borgbase/ansible-role-borgbackup.git roles/borgbackup
$ git clone https://github.com/borgbase/ansible-role-borgbackup.git roles/ansible_role_borgbackup
```

View File

@ -3,6 +3,8 @@ dependencies: []
galaxy_info:
author: Manuel Riel
role_name: ansible_role_borgbackup
namespace: m3nu
description: Set up backup to remote machine using Borg and Borgmatic.
company: "BorgBase.com"
license: license (BSD, MIT)

View File

@ -7,7 +7,7 @@
name: openssh-server
state: present
roles:
- role: ansible-role-borgbackup
- role: m3nu.ansible_role_borgbackup
borg_encryption_passphrase: CHANGEME
borg_repository: m5vz9gp4@m5vz9gp4.repo.borgbase.com:repo
borg_source_directories:

View File

@ -10,10 +10,6 @@ platforms:
image: centos:latest
- name: fedora-latest
image: fedora:latest
- name: fedora-31
image: fedora:31
- name: debian-oldstable
image: debian:oldstable
- name: debian-stable
image: debian:stable
- name: ubuntu-bionic
@ -24,3 +20,7 @@ provisioner:
name: ansible
verifier:
name: ansible
lint: |
set -e
yamllint .
ansible-lint .

View File

@ -1,3 +1,3 @@
molecule[lint,docker]
ansible
ansible-lint
testinfra
molecule[lint,docker]

View File

@ -1,7 +1 @@
---
- name: Install EPEL repo
yum:
pkg: epel-release
state: installed
update_cache: yes
when: ansible_distribution == 'CentOS' or ansible_distribution == 'Red Hat Enterprise Linux'

View File

@ -6,8 +6,9 @@
- "{{ ansible_os_family }}-{{ ansible_distribution_major_version }}.yml"
- "{{ ansible_distribution }}.yml"
- "{{ ansible_os_family }}.yml"
- "{{ ansible_lsb.id }}.yml"
- name: Run OS-specific setup
- name: Run OS-specific tasks
include: "{{ item }}"
with_first_found:
- "{{ ansible_os_family }}-{{ ansible_distribution_major_version }}.yml"
@ -39,7 +40,8 @@
ssh_key_type: ed25519
register: root_user
- debug:
- name: Print key created for root user (use for remote repo)
debug:
var: root_user['ssh_public_key']
- name: Create new repository for server

8
vars/ManjaroLinux.yml Normal file
View File

@ -0,0 +1,8 @@
---
borg_packages:
- borgmatic
- openssh
- cronie
python_bin: python3
pip_bin: pip3