-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
89 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
--- | ||
name: CI | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- master | ||
# schedule: | ||
# - cron: "0 5 * * 0" | ||
|
||
defaults: | ||
run: | ||
working-directory: 't_systems_mms.cniplugins' | ||
|
||
jobs: | ||
|
||
lint: | ||
name: Lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out the codebase. | ||
uses: actions/checkout@v2 | ||
with: | ||
path: 't_systems_mms.cniplugins' | ||
|
||
- name: Set up Python 3. | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.x' | ||
|
||
- name: Install test dependencies. | ||
run: pip3 install yamllint | ||
|
||
- name: Lint code. | ||
run: | | ||
yamllint . | ||
molecule: | ||
name: Molecule | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
distro: | ||
- centos8 | ||
- centos7 | ||
- ubuntu2004 | ||
- debian10 | ||
|
||
steps: | ||
- name: Check out the codebase. | ||
uses: actions/checkout@v2 | ||
with: | ||
path: 't_systems_mms.cniplugins' | ||
|
||
- name: Set up Python 3. | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.x' | ||
|
||
- name: Install test dependencies. | ||
run: pip3 install ansible molecule[docker] docker | ||
|
||
- name: Run Molecule tests. | ||
run: molecule test | ||
env: | ||
PY_COLORS: '1' | ||
ANSIBLE_FORCE_COLOR: '1' | ||
MOLECULE_DISTRO: ${{ matrix.distro }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,19 @@ | ||
--- | ||
scenario: | ||
scenario: | ||
name: default | ||
|
||
dependency: | ||
enabled: true | ||
name: galaxy | ||
driver: | ||
name: docker | ||
|
||
platforms: | ||
- name: docker-ubuntu | ||
image: ubuntu:bionic | ||
|
||
image: geerlingguy/docker-${MOLECULE_DISTRO:-centos7}-ansible:latest | ||
privileged: true | ||
provisioner: | ||
name: ansible | ||
lint: | | ||
yamllint . | ||
ansible-lint | ||
flake8 | ||
|
||
lint: | | ||
yamllint . | ||
ansible-lint | ||
flake8 | ||
verifier: | ||
name: testinfra | ||
env: | ||
# get rid of the DeprecationWarning messages of third-party libs, | ||
# see https://docs.pytest.org/en/latest/warnings.html#deprecationwarning-and-pendingdeprecationwarning | ||
PYTHONWARNINGS: "ignore:.*U.*mode is deprecated:DeprecationWarning" | ||
lint: | | ||
yamllint . | ||
ansible-lint | ||
flake8 | ||
options: | ||
# show which tests where executed in test output | ||
v: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
collections: | ||
- name: ansible.posix | ||
roles: [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
--- | ||
- name: install consul connect cni plugin | ||
- name: install on linux distribution cni plugin | ||
include_tasks: linux/main.yml |