Use simpler file structure
This commit is contained in:
parent
3bca1176a4
commit
7f6381b33c
17 changed files with 152 additions and 122 deletions
|
|
@ -3,40 +3,24 @@ stages:
|
|||
- test
|
||||
|
||||
cache:
|
||||
key: "$CI_COMMIT_REF_SLUG"
|
||||
key: $CI_COMMIT_REF_SLUG
|
||||
paths:
|
||||
- .cache/pip
|
||||
- node_modules/
|
||||
|
||||
lint:
|
||||
stage: lint
|
||||
image: python:3.7
|
||||
before_script:
|
||||
- pip install ansible ansible-lint --quiet
|
||||
script:
|
||||
- ansible-lint playbook.yml
|
||||
only:
|
||||
refs:
|
||||
- development
|
||||
- merge_requests
|
||||
|
||||
pretty-lint:
|
||||
stage: lint
|
||||
image: node:12
|
||||
before_script:
|
||||
- npm install
|
||||
- npm install prettier --no-save
|
||||
script:
|
||||
- npx prettier "roles/**/*.yml" --check
|
||||
only:
|
||||
refs:
|
||||
- development
|
||||
- merge_requests
|
||||
- npx prettier '**/*.yml' --check
|
||||
|
||||
syntax-test:
|
||||
stage: test
|
||||
image: python:3.7
|
||||
before_script:
|
||||
- pip install ansible ansible-lint --quiet
|
||||
- ansible-galaxy install -r roles/requirements.yml
|
||||
- pip install ansible --quiet
|
||||
- ansible-galaxy install -r requirements.yml
|
||||
script:
|
||||
- ansible-playbook playbook.yml --syntax-check
|
||||
|
|
|
|||
Reference in a new issue