Skip to content

roles-ansible/check-ansible-centos-centos10-action

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

75 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Github Marketplace MIT License

Check Ansible CentOS 10 Stream

This action allows you to test your ansible role or your playbook in a Docker Container with quay.io/centos/centos:stream10.

Usage

To use the action simply create an ansible-centos-centos10.yml (or choose custom *.yml name) in the .github/workflows/ directory.

For example:

---
name: Ansible check centos:stream10  # feel free to pick your own name

# yamllint disable-line rule:truthy
on: [push, pull_request]

jobs:
  build:
    runs-on: ubuntu-latest

    steps:
      # Important: This sets up your GITHUB_WORKSPACE environment variable
      - name: checkout git repo
        uses: actions/checkout@v3

      - name: ansible check with quay.io/centos/centos:stream10
        # optionally replace "main" with any valid git ref
        uses: roles-ansible/check-ansible-centos-centos10-action@main
        with:
          targets: "./"
          #  [required]
          #   Paths to your ansible role or playboox.yml you want to test
          #   Some Examples:
          #   targets: "role/my_role/"
          #   targets: "site.yml"
          #
          # group: ""
          #  [optional]
          #   When testing playbooks you have to tell ansible
          #   the group you that we write in our hosts file.
          #   example:
          #   group: 'servers'
          #
          # hosts: ""
          #  [optional]
          #   When testing playbooks you have to give one example
          #   host this action should use to test your playbook.
          #   > We only spawn one docker container that mean
          #   > we can only test one host at the time. Sorry
          #   some examples:
          #   hosts: 'localhost'
          #   hosts: 'srv01.example.com'
          #
          # requirements: ""
          #  [optional]
          #   When testing playbooks and you are using ansible galaxy,
          #   you may be interested in installing your requirements
          #   from ansible galaxy.
          #   To do this please provide us either the role name directly
          #   requirements: 'do1jlr.ansible_version'
          #   or your requiements.yml file.
          #   requirements: 'requirements.yml'
          #
          # tags: ""
          #  [optional]
          #   If you want to limit the test to some tags, you can use this
          #   tags or the skiptags option. It will trigger the --tags $tags
          #   option to ansible.
          #
          # skiptags: ""
          # [optional]
          #  See tags. This will trigger the --skip-tags $skiptags option
          #  to ansible.

Alternatively, you can run the ansible check only on certain branches:

on:
  push:
    branches:
    - stable
    - release/v*

or on various events


Contributing

If you are missing a feature or see a bug. Please report it. Or - if you like - open a pull-request.

License

The Dockerfile and associated scripts and documentation in this project are released under the MIT License.

Credits

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published