Skip to content

Commit

Permalink
Generated Ansible files
Browse files Browse the repository at this point in the history
  • Loading branch information
buluma committed Nov 18, 2023
1 parent 11a7fa1 commit 15f58ad
Show file tree
Hide file tree
Showing 13 changed files with 52 additions and 45 deletions.
18 changes: 9 additions & 9 deletions .ansible-lint
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
# Ansible managed
#
exclude_paths:
- ./meta/preferences.yml
- ./molecule/default/prepare.yml
- ./molecule/default/converge.yml
- ./molecule/default/verify.yml
- ./molecule/default/collections.yml
- ./.tox
- ./.cache
- ./.github
- ./requirements.yml
- meta/preferences.yml
- molecule/default/prepare.yml
- molecule/default/converge.yml
- molecule/default/verify.yml
- molecule/default/collections.yml
- .tox
- .cache
- .github
- requirements.yml

skip_list:
- yaml[truthy]
Expand Down
3 changes: 1 addition & 2 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ about: Create a report to help me improve

---

## Describe the bug
# Describe the bug

A clear and concise description of what the bug is.

Expand All @@ -13,7 +13,6 @@ A clear and concise description of what the bug is.
Please paste the playbook you are using. (Consider `requirements.yml` and
optionally the command you've invoked.)


```yaml
---
YOUR PLAYBOOK HERE
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ about: Suggest an idea for this project

---

## Proposed feature
# Proposed feature

A clear and concise description of what you want to happen.

Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/galaxy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
runs-on: ubuntu-20.04
steps:
- name: galaxy
uses: buluma/[email protected]
# uses: buluma/[email protected] # TODO: rebuild action
uses: robertdebock/[email protected]
with:
galaxy_api_key: ${{ secrets.galaxy_api_key }}
23 changes: 12 additions & 11 deletions .github/workflows/molecule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ on:
schedule:
- cron: '29 15 15 * *'

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

concurrency:
group: ${{ github.ref }}-${{ github.workflow }}
cancel-in-progress: true
Expand All @@ -29,7 +32,7 @@ jobs:
runs-on: ubuntu-20.04
steps:
- name: checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: ansible-lint
uses: ansible-community/ansible-lint-action@main
test:
Expand All @@ -48,12 +51,8 @@ jobs:
tag: "8"
- image: "debian-systemd"
tag: "latest"
- image: "debian-systemd"
tag: "buster"
- image: "debian-systemd"
tag: "bullseye"
- image: "fedora-systemd"
tag: "36"
- image: "fedora-systemd"
tag: "37"
- image: "fedora-systemd"
Expand All @@ -66,19 +65,21 @@ jobs:
tag: "focal"
- image: "docker-ubuntu-systemd"
tag: "bionic"
- image: "docker-ubuntu-systemd"
tag: "lunar"
- image: "kali"
tag: "latest"
steps:
- name: checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: "${{ github.repository }}"
- name: disable apparmor for mysql
run: sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
- name: parse apparmor for mysql
run: sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
# - name: disable apparmor for mysql
# run: sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
# - name: parse apparmor for mysql
# run: sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
- name: molecule
uses: buluma/molecule-action@v5.0.7
uses: buluma/molecule-action@v5.1.1
with:
image: ${{ matrix.config.image }}
tag: ${{ matrix.config.tag }}
9 changes: 5 additions & 4 deletions .github/workflows/requirements2png.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@
#

on:
- push

push:
paths:
- '.github/workflows/requirements2png.yml'
name: Ansible Graphviz

jobs:
Expand All @@ -15,11 +16,11 @@ jobs:
contents: write
steps:
- name: checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ${{ github.repository }}
- name: create png
uses: buluma/[email protected] # TODO: Update action
uses: buluma/[email protected] # TODO: Update action
- name: Commit files
run: |
cd ${{ github.repository }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/todo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
steps:
- uses: "actions/checkout@master"
- name: "TODO to Issue"
uses: "alstr/[email protected]" # TODO: Update buluma/[email protected] @buluma
uses: "alstr/[email protected]" # TODO: Update buluma/[email protected] @buluma
id: "todo"
with:
TOKEN: ${{ secrets.GITHUB_TOKEN }}
12 changes: 7 additions & 5 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
---
image: "buluma/github-action-molecule:5.0.7"
image: "buluma/github-action-molecule:5.1.1"

variables:
PY_COLORS: 1

molecule:
script:
- if [ -f tox.ini ] ; then tox ; fi
- if [ ! -f tox.ini ] ; then molecule test ; fi
- molecule test
rules:
- if: $CI_COMMIT_REF_NAME == "master"
allow_failure: true
parallel:
matrix:
- image: "alpine-openrc"
Expand All @@ -20,8 +20,8 @@ molecule:
tag: "8"
- image: "debian-systemd"
tag: "latest"
- image: "fedora-systemd"
tag: "36"
- image: "debian-systemd"
tag: "bullseye"
- image: "fedora-systemd"
tag: "37"
- image: "fedora-systemd"
Expand All @@ -34,6 +34,8 @@ molecule:
tag: "focal"
- image: "docker-ubuntu-systemd"
tag: "bionic"
- image: "docker-ubuntu-systemd"
tag: "lunar"
- image: "kali"
tag: "latest"

Expand Down
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
---
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
rev: v4.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-added-large-files

- repo: https://github.com/adrienverge/yamllint
rev: v1.29.0
rev: v1.32.0
hooks:
- id: yamllint
args: [-c=.yamllint]
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# [openssh](#openssh)
# [Ansible role openssh](#openssh)

Install and configure openssh on your system.

|GitHub|GitLab|Quality|Downloads|Version|Issues|Pull Requests|
|------|------|-------|---------|-------|------|-------------|
|[![github](https://github.com/buluma/ansible-role-openssh/workflows/Ansible%20Molecule/badge.svg)](https://github.com/buluma/ansible-role-openssh/actions)|[![gitlab](https://gitlab.com/shadowwalker/ansible-role-openssh/badges/master/pipeline.svg)](https://gitlab.com/shadowwalker/ansible-role-openssh)|[![quality](https://img.shields.io/ansible/quality/58009)](https://galaxy.ansible.com/buluma/openssh)|[![downloads](https://img.shields.io/ansible/role/d/58009)](https://galaxy.ansible.com/buluma/openssh)|[![Version](https://img.shields.io/github/release/buluma/ansible-role-openssh.svg)](https://github.com/buluma/ansible-role-openssh/releases/)|[![Issues](https://img.shields.io/github/issues/buluma/ansible-role-openssh.svg)](https://github.com/buluma/ansible-role-openssh/issues/)|[![PullRequests](https://img.shields.io/github/issues-pr-closed-raw/buluma/ansible-role-openssh.svg)](https://github.com/buluma/ansible-role-openssh/pulls/)|
|GitHub|GitLab|Downloads|Version|Issues|Pull Requests|
|------|------|-------|-------|------|-------------|
|[![github](https://github.com/buluma/ansible-role-openssh/workflows/Ansible%20Molecule/badge.svg)](https://github.com/buluma/ansible-role-openssh/actions)|[![gitlab](https://gitlab.com/shadowwalker/ansible-role-openssh/badges/master/pipeline.svg)](https://gitlab.com/shadowwalker/ansible-role-openssh)|[![downloads](https://img.shields.io/ansible/role/d/4787)](https://galaxy.ansible.com/buluma/openssh)|[![Version](https://img.shields.io/github/release/buluma/ansible-role-openssh.svg)](https://github.com/buluma/ansible-role-openssh/releases/)|[![Issues](https://img.shields.io/github/issues/buluma/ansible-role-openssh.svg)](https://github.com/buluma/ansible-role-openssh/issues/)|[![PullRequests](https://img.shields.io/github/issues-pr-closed-raw/buluma/ansible-role-openssh.svg)](https://github.com/buluma/ansible-role-openssh/pulls/)|

## [Example Playbook](#example-playbook)

Expand Down
1 change: 1 addition & 0 deletions molecule/default/molecule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ platforms:
command: /sbin/init
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup:rw
cgroupns_mode: host
privileged: yes
pre_build_image: yes
provisioner:
Expand Down
5 changes: 2 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Pinning ansible-compat version due to [bug](https://github.com/ansible-community/molecule/issues/3903)
ansible-compat == 3.0.2
molecule == 5.*
ansible-compat == 4.*
molecule == 6.*
molecule-plugins[docker] == 23.*
ansible-lint == 6.*
paramiko == 3.*
Expand Down
7 changes: 5 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,19 @@
#
[tox]
minversion = 4.2.4
envlist = py{311}-ansible{5,6,7}
# Ansible 6 and 7 are disabled, causing issues with Fedora:
# https://github.com/ansible/ansible/issues/81199#event-9773321055
# envlist = py3-ansible{6,7,8}
envlist = py3-ansible{8}

skipsdist = true

[testenv]
deps =
-rrequirements.txt
ansible5: ansible == 5.*
ansible6: ansible == 6.*
ansible7: ansible == 7.*
ansible8: ansible == 8.*
commands = molecule test
setenv =
TOX_ENVNAME={envname}
Expand Down

0 comments on commit 15f58ad

Please sign in to comment.