2021-02-21 19:50:07 +00:00
|
|
|
---
|
2021-02-10 16:48:51 +00:00
|
|
|
name: CI
|
|
|
|
|
2022-07-26 07:55:43 +00:00
|
|
|
# Controls when the action will run.
|
2021-02-10 16:48:51 +00:00
|
|
|
on:
|
|
|
|
# Triggers the workflow on push or pull request events but only for the master branch
|
|
|
|
push:
|
2022-07-26 07:55:43 +00:00
|
|
|
branches: [master]
|
2021-02-10 16:48:51 +00:00
|
|
|
pull_request:
|
2022-07-26 07:55:43 +00:00
|
|
|
branches: [master]
|
2021-02-10 16:48:51 +00:00
|
|
|
|
|
|
|
# Allows you to run this workflow manually from the Actions tab
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
lint:
|
|
|
|
name: Lint
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2021-02-10 23:52:17 +00:00
|
|
|
- name: Check out the codebase
|
2021-02-10 16:48:51 +00:00
|
|
|
uses: actions/checkout@v2
|
|
|
|
|
2021-02-10 23:52:17 +00:00
|
|
|
- name: Set up Python 3
|
2021-02-10 16:48:51 +00:00
|
|
|
uses: actions/setup-python@v2
|
|
|
|
with:
|
2022-07-26 07:55:43 +00:00
|
|
|
python-version: "3.x"
|
2021-02-10 16:48:51 +00:00
|
|
|
|
2021-02-10 23:52:17 +00:00
|
|
|
- name: Install test dependencies
|
2022-02-05 14:05:01 +00:00
|
|
|
run: pip3 install ansible yamllint ansible-lint
|
2021-02-10 16:48:51 +00:00
|
|
|
|
2022-07-26 08:12:43 +00:00
|
|
|
- name: Lint yaml files
|
2021-02-21 19:50:07 +00:00
|
|
|
run: |
|
2022-02-05 14:05:01 +00:00
|
|
|
ansible-lint nas.yml
|
2021-02-21 19:50:07 +00:00
|
|
|
yamllint .
|
2022-07-26 07:55:43 +00:00
|
|
|
|
2022-07-26 08:12:43 +00:00
|
|
|
- name: Lint docs
|
2022-07-26 07:55:43 +00:00
|
|
|
uses: articulate/actions-markdownlint@v1
|
|
|
|
with:
|
2022-07-26 08:05:54 +00:00
|
|
|
config: markdownlint-config.json
|
2022-07-26 07:55:43 +00:00
|
|
|
files: "docs/**/*.md"
|