From b018fae6d0c20f0c3ba8d0cb041ab6d1e7bd588d Mon Sep 17 00:00:00 2001 From: L3D Date: Fri, 12 Mar 2021 14:47:22 +0100 Subject: [PATCH] update github actions --- .github/workflows/ansible-centos-centos7.yml | 12 +++++---- .github/workflows/ansible-centos-centos8.yml | 12 +++++---- .github/workflows/ansible-centos-latest.yml | 12 +++++---- .github/workflows/ansible-linting-check.yml | 28 ++++++++++++++++++++ .github/workflows/galaxy.yml | 20 ++++++++++++++ .github/workflows/yamllint.yaml | 24 +++++++++++++++++ 6 files changed, 93 insertions(+), 15 deletions(-) create mode 100644 .github/workflows/ansible-linting-check.yml create mode 100644 .github/workflows/galaxy.yml create mode 100644 .github/workflows/yamllint.yaml diff --git a/.github/workflows/ansible-centos-centos7.yml b/.github/workflows/ansible-centos-centos7.yml index 90bff41..401d2c0 100644 --- a/.github/workflows/ansible-centos-centos7.yml +++ b/.github/workflows/ansible-centos-centos7.yml @@ -1,5 +1,7 @@ +--- name: Ansible check centos:centos7 +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:centos7 - uses: roles-ansible/check-ansible-centos-centos7-action@master - with: - targets: "./" + - name: ansible check with ubuntu:centos7 + uses: roles-ansible/check-ansible-centos-centos7-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-centos-centos8.yml b/.github/workflows/ansible-centos-centos8.yml index 5d7acc9..f20097b 100644 --- a/.github/workflows/ansible-centos-centos8.yml +++ b/.github/workflows/ansible-centos-centos8.yml @@ -1,5 +1,7 @@ +--- name: Ansible check centos:centos8 +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:centos8 - uses: roles-ansible/check-ansible-centos-centos8-action@master - with: - targets: "./" + - name: ansible check with ubuntu:centos8 + uses: roles-ansible/check-ansible-centos-centos8-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-centos-latest.yml b/.github/workflows/ansible-centos-latest.yml index de991de..94eb54b 100644 --- a/.github/workflows/ansible-centos-latest.yml +++ b/.github/workflows/ansible-centos-latest.yml @@ -1,5 +1,7 @@ +--- name: Ansible check centos:latest +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:latest - uses: roles-ansible/check-ansible-centos-latest-action@master - with: - targets: "./" + - name: ansible check with ubuntu:latest + uses: roles-ansible/check-ansible-centos-latest-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-linting-check.yml b/.github/workflows/ansible-linting-check.yml new file mode 100644 index 0000000..7973217 --- /dev/null +++ b/.github/workflows/ansible-linting-check.yml @@ -0,0 +1,28 @@ +--- +name: Ansible Lint check + +# yamllint disable-line rule:truthy +on: + push: + branches: '*' + pull_request: + branches: '*' + schedule: + - cron: '42 6 * */1 *' + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Lint Ansible Playbook + uses: ansible/ansible-lint-action@master + with: + targets: "." + # [required] + # Paths to ansible files (i.e., playbooks, tasks, handlers etc..) + args: "" + # [optional] diff --git a/.github/workflows/galaxy.yml b/.github/workflows/galaxy.yml new file mode 100644 index 0000000..fc9cd63 --- /dev/null +++ b/.github/workflows/galaxy.yml @@ -0,0 +1,20 @@ +--- +name: Galaxy release + +# yamllint disable-line rule:truthy +on: + push: + branches: ['main'] + release: + types: ['created'] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: checkout + uses: actions/checkout@v2 + - name: galaxy + uses: robertdebock/galaxy-action@1.1.0 + with: + galaxy_api_key: ${{ secrets.galaxy_api_key }} diff --git a/.github/workflows/yamllint.yaml b/.github/workflows/yamllint.yaml new file mode 100644 index 0000000..ddb5b89 --- /dev/null +++ b/.github/workflows/yamllint.yaml @@ -0,0 +1,24 @@ +--- +name: 'Yamllint GitHub Actions' + +# yamllint disable-line rule:truthy +on: + push: + branches: '*' + pull_request: + branches: '*' + schedule: + - cron: '23 6 * */1 *' + +jobs: + yamllint: + name: 'Yamllint' + runs-on: ubuntu-latest + steps: + - name: 'Checkout' + uses: actions/checkout@master + - name: 'Yamllint' + uses: karancode/yamllint-github-action@master + with: + yamllint_file_or_dir: '.' + yamllint_config_filepath: './.yamllint'