You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
604 B
23 lines
604 B
---
|
|
- name: Service Tag Retriever
|
|
hosts: proxmox
|
|
tasks:
|
|
- name: Confirm directory structure
|
|
ansible.builtin.file:
|
|
path: /opt/ansible/
|
|
state: directory
|
|
- name: Ensure service tag script is present
|
|
ansible.builtin.copy:
|
|
src: ~/ansible/files/servicetag.sh
|
|
dest: /opt/ansible/servicetag.sh
|
|
mode: '0755'
|
|
force: yes
|
|
- name: Execute service tag script
|
|
ansible.builtin.command:
|
|
chdir: /opt/ansible
|
|
cmd: ./servicetag.sh
|
|
register: stdout
|
|
- name: Display service tags
|
|
debug:
|
|
var=stdout.stdout
|