28 lines
949 B
YAML
28 lines
949 B
YAML
---
|
|
- name: Update Regression Test Script
|
|
hosts: airflow_master
|
|
gather_facts: no
|
|
vars:
|
|
# This should be the root directory of your project on the master host.
|
|
# It's set as a variable so you can override it if needed, e.g.,
|
|
# ansible-playbook ... -e "project_dir=/path/to/your/project"
|
|
project_dir: "/srv/airflow_master"
|
|
|
|
tasks:
|
|
- name: Copy latest regression.py script to the master host
|
|
copy:
|
|
src: ../airflow/dags/scripts/regression.py
|
|
dest: "{{ project_dir }}/dags/scripts/regression.py"
|
|
owner: "{{ ansible_user }}"
|
|
group: "ytdl" # Assuming the same deploy group as the main playbook
|
|
mode: '0644'
|
|
become: yes
|
|
notify:
|
|
- Announce completion
|
|
|
|
handlers:
|
|
- name: Announce completion
|
|
listen: "Announce completion"
|
|
debug:
|
|
msg: "Regression script has been updated on {{ inventory_hostname }}. You can now run it using 'docker exec'."
|