From 6166c3f3ea3f85ac244a9572007b92af2380e046 Mon Sep 17 00:00:00 2001 From: = <=> Date: Sat, 14 Jun 2025 20:18:31 +0200 Subject: [PATCH 1/3] add CI --- .forgejo/workflows/ansible-ci.yml | 39 +++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 .forgejo/workflows/ansible-ci.yml diff --git a/.forgejo/workflows/ansible-ci.yml b/.forgejo/workflows/ansible-ci.yml new file mode 100644 index 0000000..423c38c --- /dev/null +++ b/.forgejo/workflows/ansible-ci.yml @@ -0,0 +1,39 @@ +name: Ansible CI + +on: + push: + branches: + - main + pull_request: + +jobs: + lint_and_vault_check: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Setup Python + uses: actions/setup-python@v4 + with: + python-version: '3.x' + + - name: Install ansible and ansible-lint + run: | + python -m pip install --upgrade pip + pip install ansible ansible-lint + + - name: Run ansible-lint + run: ansible-lint + + - name: Check if all inventory files are ansible-vault encrypted + run: | + set -e + INVENTORY_DIR="./inventory" + for file in $(find "$INVENTORY_DIR" -type f); do + if ! head -1 "$file" | grep -q '$ANSIBLE_VAULT'; then + echo "ERROR: Inventory file $file is NOT ansible-vault encrypted!" + exit 1 + fi + done \ No newline at end of file From b6907dd51631eb493a238859dc6f05dacdbde81f Mon Sep 17 00:00:00 2001 From: = <=> Date: Sat, 14 Jun 2025 20:35:34 +0200 Subject: [PATCH 2/3] remove CI --- .forgejo/workflows/ansible-ci.yml | 39 ------------------------------- 1 file changed, 39 deletions(-) delete mode 100644 .forgejo/workflows/ansible-ci.yml diff --git a/.forgejo/workflows/ansible-ci.yml b/.forgejo/workflows/ansible-ci.yml deleted file mode 100644 index 423c38c..0000000 --- a/.forgejo/workflows/ansible-ci.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: Ansible CI - -on: - push: - branches: - - main - pull_request: - -jobs: - lint_and_vault_check: - runs-on: ubuntu-latest - - steps: - - name: Checkout repository - uses: actions/checkout@v3 - - - name: Setup Python - uses: actions/setup-python@v4 - with: - python-version: '3.x' - - - name: Install ansible and ansible-lint - run: | - python -m pip install --upgrade pip - pip install ansible ansible-lint - - - name: Run ansible-lint - run: ansible-lint - - - name: Check if all inventory files are ansible-vault encrypted - run: | - set -e - INVENTORY_DIR="./inventory" - for file in $(find "$INVENTORY_DIR" -type f); do - if ! head -1 "$file" | grep -q '$ANSIBLE_VAULT'; then - echo "ERROR: Inventory file $file is NOT ansible-vault encrypted!" - exit 1 - fi - done \ No newline at end of file From a3bc3941cbb68ec6104ceac755f8a0da30993f83 Mon Sep 17 00:00:00 2001 From: = <=> Date: Mon, 16 Jun 2025 18:01:59 +0200 Subject: [PATCH 3/3] add requirements --- requirements.yml | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 requirements.yml diff --git a/requirements.yml b/requirements.yml new file mode 100644 index 0000000..d764e63 --- /dev/null +++ b/requirements.yml @@ -0,0 +1,3 @@ +--- +collections: + - name: community.docker \ No newline at end of file