polytech-ansible-2023/.gitea/workflows/on_push_master.yml
Thomas Maurice 4667b5de57
All checks were successful
Master branch: build & lint / build (push) Successful in 1m8s
upgrade(README): Improve README, clarify instructions and add documentation links
2024-03-24 12:46:12 +01:00

35 lines
957 B
YAML

---
name: "Master branch: build & lint"
# yamllint disable-line rule:truthy
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-python@v5
with:
python-version: '3.10.13'
- name: "Creates virtual environment"
run: make venv
# Loads up the virtualenv
- name: Activate virtualenv
run: |
source venv/bin/activate
echo PATH=$PATH >> $GITHUB_ENV
# Installs playbooks we are using
- name: Install galaxy requirements
run: ansible-galaxy install -r requirements.yml
# Checks for yaml correctness
- name: "Run YAML linting"
run: yamllint -c .yamllint.yml .
# Runs an *ansible specific* linter to check for mistakes
# and or/bad patterns
- name: "Run Ansible linting"
run: ansible-lint