From 2322676f42f8d6fbc50ac443bccce551f7bff05c Mon Sep 17 00:00:00 2001 From: Falk Scheerschmidt Date: Sat, 22 Oct 2022 17:37:08 +0200 Subject: [PATCH] =?UTF-8?q?=E2=9C=85=20Add=20Test=20for=20Workflow?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../workflows/ansible-integration-workflow.yaml | 3 --- .github/workflows/integration.yml | 14 ++++++++++++++ README.md | 2 ++ molecule/default/converge.yml | 16 ++++++++++++++++ 4 files changed, 32 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/integration.yml create mode 100644 molecule/default/converge.yml diff --git a/.github/workflows/ansible-integration-workflow.yaml b/.github/workflows/ansible-integration-workflow.yaml index f85882a..2877c7f 100644 --- a/.github/workflows/ansible-integration-workflow.yaml +++ b/.github/workflows/ansible-integration-workflow.yaml @@ -56,9 +56,6 @@ jobs: - name: Ansible Lint uses: ansible-community/ansible-lint-action@v6 - - name: YAMLLint - uses: ibiqlik/action-yamllint@v3 - test: name: Molecule runs-on: ubuntu-22.04 diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml new file mode 100644 index 0000000..2aa347a --- /dev/null +++ b/.github/workflows/integration.yml @@ -0,0 +1,14 @@ +name: Integration + +on: + push: + branches: + - main + pull_request: + +jobs: + integration: + name: Integration + uses: ./.github/workflows/ansible-integration-workflow.yaml + with: + distros: '[ "debian11", "debian10", "ubuntu2204", "ubuntu2004" ]' diff --git a/README.md b/README.md index 59c183e..50a51ed 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Github Workflows for Ansible Roles +[![Integration](https://github.com/systemli/github-ansible-workflow/actions/workflows/integration.yml/badge.svg)](https://github.com/systemli/github-ansible-workflow/actions/workflows/integration.yml) + ## Continuous Integration (Molecule) ### Configuration diff --git a/molecule/default/converge.yml b/molecule/default/converge.yml new file mode 100644 index 0000000..c8db531 --- /dev/null +++ b/molecule/default/converge.yml @@ -0,0 +1,16 @@ +--- +- name: Converge + hosts: all + become: true + tasks: + - name: Create directory + ansible.builtin.file: + path: "/etc/molecule" + state: "directory" + mode: "0755" + + - name: Copy content to an example file + ansible.builtin.copy: + content: "This is a test" + dest: "/etc/molecule/test.txt" + mode: "0644"