Refactor CI pipelien and enable molecule testing #1
39
.drone.yml
39
.drone.yml
@ -1,36 +1,3 @@
|
|||||||
---
|
|
||||||
kind: pipeline
|
|
||||||
name: linting
|
|
||||||
|
|
||||||
platform:
|
|
||||||
os: linux
|
|
||||||
arch: amd64
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: ansible-latest
|
|
||||||
pull: always
|
|
||||||
image: python:3.7
|
|
||||||
commands:
|
|
||||||
- pip install ansible ansible-later -qq
|
|
||||||
- git clone https://gitea.rknet.org/ansible/ansible-later-policy.git ~/policy
|
|
||||||
- "git ls-files *[^LICENSE,.md,molecule,.ini] | xargs ansible-later -c ~/policy/config.ini"
|
|
||||||
environment:
|
|
||||||
PY_COLORS: 1
|
|
||||||
depends_on:
|
|
||||||
- clone
|
|
||||||
|
|
||||||
- name: ansible-master
|
|
||||||
pull: always
|
|
||||||
image: python:3.7
|
|
||||||
commands:
|
|
||||||
- "pip install git+https://github.com/ansible/ansible.git@devel ansible-later -qq"
|
|
||||||
- git clone https://gitea.rknet.org/ansible/ansible-later-policy.git ~/policy
|
|
||||||
- "git ls-files *[^LICENSE,.md,molecule,.ini] | xargs ansible-later -c ~/policy/config.ini"
|
|
||||||
environment:
|
|
||||||
PY_COLORS: 1
|
|
||||||
depends_on:
|
|
||||||
- clone
|
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
name: deployment
|
name: deployment
|
||||||
@ -48,6 +15,7 @@ steps:
|
|||||||
pull: always
|
pull: always
|
||||||
image: xoxys/molecule:gce
|
image: xoxys/molecule:gce
|
||||||
commands:
|
commands:
|
||||||
|
- '[ "$MOLECULE_CUSTOM_MODULES_REPO" ] && echo "Test"'
|
||||||
- /bin/bash /docker-entrypoint.sh
|
- /bin/bash /docker-entrypoint.sh
|
||||||
- molecule create --scenario-name gce-centos-7
|
- molecule create --scenario-name gce-centos-7
|
||||||
- molecule converge --scenario-name gce-centos-7
|
- molecule converge --scenario-name gce-centos-7
|
||||||
@ -67,8 +35,3 @@ steps:
|
|||||||
from_secret: gce_ssh_user
|
from_secret: gce_ssh_user
|
||||||
MOLECULE_CUSTOM_MODULES_REPO: https://gitea.rknet.org/ansible/custom_modules
|
MOLECULE_CUSTOM_MODULES_REPO: https://gitea.rknet.org/ansible/custom_modules
|
||||||
PY_COLORS: 1
|
PY_COLORS: 1
|
||||||
|
|
||||||
depends_on:
|
|
||||||
- linting
|
|
||||||
|
|
||||||
...
|
|
||||||
|
Loading…
Reference in New Issue
Block a user