dvirlabs c83725a027
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
Make this repo generic
2026-05-20 16:07:38 +03:00

31 lines
1.7 KiB
YAML

---
# =============================================================================
# APPLY PLAYBOOK
# Purpose: Deploy dvir.txt file to target servers at /tmp/dvir.txt
# Usage: ansible-playbook apply.yml
# =============================================================================
- name: Deploy file to servers
hosts: all
become: true
tasks:
# ─────────────────────────────────────────────────────────────────────
# TASK 1: Copy file to destination
# Copies the dvir.txt from the repo to /tmp/dvir.txt on target servers
# ─────────────────────────────────────────────────────────────────────
- name: Copy file to destination
copy:
src: ../../files/dvir.txt
dest: /tmp/dvir.txt
owner: root
group: root
mode: "0644"
# ─────────────────────────────────────────────────────────────────────
# TASK 2: Confirm deployment success
# Displays success message with the hostname for verification
# ─────────────────────────────────────────────────────────────────────
- name: Confirm deployment
debug:
msg: "✅ File deployed successfully to /tmp/dvir.txt on {{ inventory_hostname }}"