chore: add dev/prod to ansible playbooks
This commit is contained in:
@@ -55,10 +55,13 @@ jobs:
|
||||
run: |
|
||||
uv run ansible-galaxy collection install -r ansible/collections/requirements.yml -p ./ansible/installed-collections
|
||||
|
||||
# TODO: dev/prod
|
||||
- name: Run New Service Playbook
|
||||
working-directory: ansible
|
||||
run: |
|
||||
uv run ansible-playbook playbooks/add-new-service.yml \
|
||||
-i hosts.yml \
|
||||
--extra-vars="repo_root=${{ github.workspace }} agebd_env=dev service_name_lower=${{ steps.parse_branch.outputs.service_name_lower }}" \
|
||||
-v
|
||||
-i "inventories/dev/hosts.yml" \
|
||||
--extra-vars="repo_root=${{ github.workspace }}" \
|
||||
--extra-vars="agebd_env=dev" \
|
||||
--extra-vars="service_name_lower=${{ steps.parse_branch.outputs.service_name_lower }}" \
|
||||
-v
|
||||
|
||||
@@ -98,6 +98,6 @@ jobs:
|
||||
|
||||
# 3. Fire the playbook passing variables down
|
||||
ansible-playbook playbooks/deploy-and-restart-modified-services.yml \
|
||||
-i hosts.yml \
|
||||
-e "changed_services_raw='$CHANGED_SVC'" \
|
||||
-e "agebd_env=$AGEBD_ENV"
|
||||
-i "inventories/$AGEBD_ENV/hosts.yml" \
|
||||
--extra-vars="changed_services_raw='$CHANGED_SVC'" \
|
||||
--extra-vars="agebd_env=$AGEBD_ENV"
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
all:
|
||||
lc:
|
||||
hosts:
|
||||
sls-lc:
|
||||
ansible_remote_tmp: /tmp/.ansible_${ansible_user}_tmp
|
||||
sls-vserv-bd-hla01-dev:
|
||||
vserv:
|
||||
hosts:
|
||||
sls-vserv-bd-01-dev:
|
||||
ansible_ssh_pipelining: true
|
||||
ansible_ssh_pipelining: true
|
||||
vserv-hla:
|
||||
hosts:
|
||||
sls-vserv-bd-hla01-dev:
|
||||
@@ -0,0 +1,11 @@
|
||||
lc:
|
||||
hosts:
|
||||
sls-lca:
|
||||
ansible_remote_tmp: /tmp/.ansible_${ansible_user}_tmp
|
||||
vserv:
|
||||
hosts:
|
||||
sls-vserv-bd-01:
|
||||
ansible_ssh_pipelining: true
|
||||
vserv-hla:
|
||||
hosts:
|
||||
sls-vserv-bd-hla01:
|
||||
@@ -1,7 +1,6 @@
|
||||
---
|
||||
- name: Add a new service
|
||||
# TODO: dev/prod
|
||||
hosts: sls-vserv-bd-hla01-dev
|
||||
hosts: vserv-hla
|
||||
connection: local
|
||||
gather_facts: true # Gather once here, available to all included tasks!
|
||||
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
---
|
||||
- name: Deploy and Restart Modified Services
|
||||
# TODO: dev/prod
|
||||
hosts: sls-vserv-bd-hla01-dev
|
||||
hosts: vserv-hla
|
||||
connection: local
|
||||
|
||||
vars:
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
---
|
||||
- name: Install an IOC
|
||||
# TODO: dev/prod
|
||||
hosts: sls-lc
|
||||
hosts: lc
|
||||
gather_facts: false
|
||||
|
||||
vars:
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
---
|
||||
- name: Restart an IOC
|
||||
# TODO: dev/prod
|
||||
hosts: sls-lc
|
||||
hosts: lc
|
||||
gather_facts: false
|
||||
|
||||
vars:
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
---
|
||||
- name: Start an IOC
|
||||
# TODO: dev/prod
|
||||
hosts: sls-vserv-bd-01-dev
|
||||
hosts: vserv
|
||||
gather_facts: false
|
||||
|
||||
tasks:
|
||||
|
||||
Reference in New Issue
Block a user