2019-04-17 15:32:03 +00:00
|
|
|
---
|
2019-04-16 12:35:05 +00:00
|
|
|
yamllint:
|
|
|
|
extends: .job
|
|
|
|
stage: unit-tests
|
2020-03-13 17:29:22 +00:00
|
|
|
tags: [light]
|
2019-12-11 08:10:05 +00:00
|
|
|
variables:
|
|
|
|
LANG: C.UTF-8
|
2019-04-16 12:35:05 +00:00
|
|
|
script:
|
2019-04-20 13:15:41 +00:00
|
|
|
- yamllint --strict .
|
2019-04-16 12:35:05 +00:00
|
|
|
except: ['triggers', 'master']
|
|
|
|
|
2019-05-02 18:24:21 +00:00
|
|
|
vagrant-validate:
|
|
|
|
extends: .job
|
|
|
|
stage: unit-tests
|
2020-03-13 17:29:22 +00:00
|
|
|
tags: [light]
|
2019-12-17 15:11:59 +00:00
|
|
|
variables:
|
2020-09-17 09:36:46 +00:00
|
|
|
VAGRANT_VERSION: 2.2.10
|
2019-05-02 18:24:21 +00:00
|
|
|
script:
|
2019-12-17 15:11:59 +00:00
|
|
|
- ./tests/scripts/vagrant-validate.sh
|
2019-05-02 18:24:21 +00:00
|
|
|
except: ['triggers', 'master']
|
|
|
|
|
2019-04-16 12:35:05 +00:00
|
|
|
ansible-lint:
|
|
|
|
extends: .job
|
|
|
|
stage: unit-tests
|
2020-03-13 17:29:22 +00:00
|
|
|
tags: [light]
|
2019-04-16 12:35:05 +00:00
|
|
|
# lint every yml/yaml file that looks like it contains Ansible plays
|
|
|
|
script: |-
|
2019-04-29 12:12:22 +00:00
|
|
|
grep -Rl '^- hosts: \|^ hosts: ' --include \*.yml --include \*.yaml . | xargs -P 4 -n 25 ansible-lint -v
|
2019-04-16 12:35:05 +00:00
|
|
|
except: ['triggers', 'master']
|
|
|
|
|
|
|
|
syntax-check:
|
|
|
|
extends: .job
|
|
|
|
stage: unit-tests
|
2020-03-13 17:29:22 +00:00
|
|
|
tags: [light]
|
2019-04-20 13:37:40 +00:00
|
|
|
variables:
|
|
|
|
ANSIBLE_INVENTORY: inventory/local-tests.cfg
|
|
|
|
ANSIBLE_REMOTE_USER: root
|
|
|
|
ANSIBLE_BECOME: "true"
|
|
|
|
ANSIBLE_BECOME_USER: root
|
|
|
|
ANSIBLE_VERBOSITY: "3"
|
2019-04-16 12:35:05 +00:00
|
|
|
script:
|
2019-04-20 13:37:40 +00:00
|
|
|
- ansible-playbook --syntax-check cluster.yml
|
|
|
|
- ansible-playbook --syntax-check upgrade-cluster.yml
|
|
|
|
- ansible-playbook --syntax-check reset.yml
|
|
|
|
- ansible-playbook --syntax-check extra_playbooks/upgrade-only-k8s.yml
|
2019-04-16 12:35:05 +00:00
|
|
|
except: ['triggers', 'master']
|
|
|
|
|
|
|
|
tox-inventory-builder:
|
|
|
|
stage: unit-tests
|
2020-03-13 17:29:22 +00:00
|
|
|
tags: [light]
|
2019-04-16 12:35:05 +00:00
|
|
|
extends: .job
|
2019-12-05 09:48:32 +00:00
|
|
|
before_script:
|
|
|
|
- ./tests/scripts/rebase.sh
|
|
|
|
- apt-get update && apt-get install -y python3-pip
|
|
|
|
- update-alternatives --install /usr/bin/python python /usr/bin/python3 10
|
|
|
|
- python -m pip install -r tests/requirements.txt
|
2019-04-16 12:35:05 +00:00
|
|
|
script:
|
2019-12-05 09:48:32 +00:00
|
|
|
- pip3 install tox
|
2019-04-16 12:35:05 +00:00
|
|
|
- cd contrib/inventory_builder && tox
|
|
|
|
except: ['triggers', 'master']
|
2019-12-04 15:22:57 +00:00
|
|
|
|
|
|
|
markdownlint:
|
|
|
|
stage: unit-tests
|
2020-03-13 17:29:22 +00:00
|
|
|
tags: [light]
|
2019-12-04 15:22:57 +00:00
|
|
|
image: node
|
|
|
|
before_script:
|
2020-12-22 12:44:26 +00:00
|
|
|
- npm install -g markdownlint-cli@0.22.0
|
2019-12-04 15:22:57 +00:00
|
|
|
script:
|
2020-12-30 13:07:49 +00:00
|
|
|
- markdownlint $(find . -name "*.md" | grep -v .github) --ignore docs/_sidebar.md --ignore contrib/dind/README.md
|
2020-04-23 16:51:11 +00:00
|
|
|
|
|
|
|
ci-matrix:
|
|
|
|
stage: unit-tests
|
|
|
|
tags: [light]
|
|
|
|
image: python:3
|
|
|
|
script:
|
|
|
|
- tests/scripts/md-table/test.sh
|