88 lines
1.1 KiB
YAML
88 lines
1.1 KiB
YAML
---
|
|
kind: pipeline
|
|
type: exec
|
|
name: check on test
|
|
|
|
trigger:
|
|
event:
|
|
- push
|
|
- pull_request
|
|
|
|
steps:
|
|
- name: Check playbook
|
|
commands:
|
|
- ansible-playbook -C playbook.yml
|
|
|
|
node:
|
|
target: local
|
|
---
|
|
kind: pipeline
|
|
type: exec
|
|
name: deploy to prod
|
|
|
|
steps:
|
|
- name: Check playbook
|
|
commands:
|
|
- ansible-playbook -C playbook.yml
|
|
|
|
- name: Run playbook
|
|
commands:
|
|
- ansible-playbook playbook.yml
|
|
|
|
node:
|
|
target: shell-scripts
|
|
|
|
trigger:
|
|
event:
|
|
- promote
|
|
target:
|
|
- production
|
|
|
|
|
|
---
|
|
kind: pipeline
|
|
type: exec
|
|
name: deploy to local test
|
|
|
|
steps:
|
|
- name: Check playbook
|
|
commands:
|
|
- ansible-playbook -C playbook.yml
|
|
|
|
- name: Run playbook
|
|
commands:
|
|
- ansible-playbook playbook.yml
|
|
|
|
node:
|
|
target: local
|
|
|
|
trigger:
|
|
event:
|
|
- promote
|
|
target:
|
|
- local
|
|
---
|
|
kind: pipeline
|
|
type: exec
|
|
name: deploy to public test
|
|
|
|
steps:
|
|
- name: Check playbook
|
|
commands:
|
|
- ansible-playbook -C playbook.yml
|
|
|
|
- name: Run playbook
|
|
commands:
|
|
- ansible-playbook playbook.yml
|
|
|
|
node:
|
|
target: shell-testing
|
|
|
|
trigger:
|
|
event:
|
|
- promote
|
|
target:
|
|
- testing
|
|
|
|
|