1
0
Fork 0
mirror of https://github.com/roles-ansible/ansible_role_versioncheck.git synced 2024-08-16 15:59:49 +02:00

Merge pull request #6 from roles-ansible/new

use new ansible syntax
This commit is contained in:
L3D 2021-03-12 00:47:54 +01:00 committed by GitHub
commit 6d2609a130
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 45 additions and 11 deletions

View file

@ -2,7 +2,13 @@
name: Ansible check debian:stable name: Ansible check debian:stable
# yamllint disable-line rule:truthy # yamllint disable-line rule:truthy
on: [push, pull_request] on:
push:
branches: '*'
pull_request:
branches: '*'
schedule:
- cron: '23 6 * */1 *'
jobs: jobs:
build: build:

View file

@ -2,7 +2,13 @@
name: Ansible Lint check name: Ansible Lint check
# yamllint disable-line rule:truthy # yamllint disable-line rule:truthy
on: [push, pull_request] on:
push:
branches: '*'
pull_request:
branches: '*'
schedule:
- cron: '42 6 * */1 *'
jobs: jobs:
build: build:

19
.github/workflows/galaxy.yml vendored Normal file
View file

@ -0,0 +1,19 @@
---
name: Galaxy release
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 }}

View file

@ -2,7 +2,13 @@
name: 'Yamllint GitHub Actions' name: 'Yamllint GitHub Actions'
# yamllint disable-line rule:truthy # yamllint disable-line rule:truthy
on: [push, pull_request] on:
push:
branches: '*'
pull_request:
branches: '*'
schedule:
- cron: '23 6 * */1 *'
jobs: jobs:
yamllint: yamllint:
@ -16,7 +22,3 @@ jobs:
with: with:
yamllint_file_or_dir: '.' yamllint_file_or_dir: '.'
yamllint_config_filepath: './.yamllint' yamllint_config_filepath: './.yamllint'
yamllint_strict: false
yamllint_comment: true
# env:
# GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
.cache

View file

@ -1,10 +1,10 @@
--- ---
galaxy_info: galaxy_info:
author: L3D author: do1jlr
description: Make sure you are only executing ansible with at least a specific ansible version. description: Make sure you are only executing ansible with at least a specific ansible version.
license: "MIT" license: "MIT"
min_ansible_version: 2.7 min_ansible_version: 2.8
github_branch: master github_branch: main
role_name: ansible_version role_name: ansible_version
platforms: platforms:
- name: Archlinux - name: Archlinux

View file

@ -1,6 +1,6 @@
--- ---
- name: "check if ansible version is above {{ check_ansible_version }}" - name: "check if ansible version is above {{ check_ansible_version }}"
assert: ansible.builtin.assert:
that: that:
- "ansible_version.full is version_compare(check_ansible_version, '>=')" - "ansible_version.full is version_compare(check_ansible_version, '>=')"
fail_msg: "[ERROR] You need at least ansible version {{ check_ansible_version }}. Current Version: {{ ansible_version.full }}" fail_msg: "[ERROR] You need at least ansible version {{ check_ansible_version }}. Current Version: {{ ansible_version.full }}"