DockerCompose/.forgejo/workflows/lint.yaml

31 lines
765 B
YAML
Raw Normal View History

2023-10-21 11:50:27 -04:00
name: Docker Compose Linter
2023-10-21 13:27:36 -04:00
on: [push] # yamllint disable-line rule:truthy
2023-10-21 11:50:27 -04:00
jobs:
Docker Compose Linter:
runs-on: docker
2023-10-21 12:08:45 -04:00
container: catthehacker/ubuntu:act-latest
2023-10-21 11:50:27 -04:00
steps:
2023-10-21 11:54:30 -04:00
- name: Checkout Repository
uses: actions/checkout@v3
2023-10-21 11:50:27 -04:00
2023-10-21 11:57:23 -04:00
- name: Install Linter
2023-10-21 12:09:12 -04:00
run: pip install yamllint
2023-10-21 11:57:23 -04:00
2023-10-21 11:54:30 -04:00
- name: Lint YAML
2023-10-21 12:01:26 -04:00
id: yaml-lint
2023-10-21 11:54:30 -04:00
uses: actions/yamllint@v3
2023-10-21 13:27:36 -04:00
with:
strict: true
config_data: |
extends: default
rules:
document-start: disable
line-length: disable
2023-10-21 11:50:27 -04:00
2023-10-21 11:55:19 -04:00
- name: Upload logs
uses: actions/upload-artifact@v3
2023-10-21 11:50:27 -04:00
if: always()
with:
2023-10-21 13:22:00 -04:00
name: logs.txt
2023-10-21 11:50:27 -04:00
path: ${{ steps.yaml-lint.outputs.logfile }}