nwl-ci/playbooks/getting_started/start-stop-nwl-jenkins.yml

17 lines
433 B
YAML

- name: Start or Stop NWL Jenkins Instance
hosts: linux
gather_facts: false
vars:
root_path: "~/nwl-ci"
tasks:
- name: Start/Stop the NWL Jenkins instance with docker-compose
ansible.builtin.shell: |
if [[ "{{power_status}}" == "start" ]]; then
docker-compose up -d
else
docker-compose down
fi
args:
chdir: "{{root_path}}"
executable: /bin/bash