Get ansible commands return value

0 votes
I need to get the return value of all ansible commands, can I write a playbook for this?
Feb 4, 2019 in Ansible by Hina
3,909 views

1 answer to this question.

0 votes

Hey @Hina, you can add the following lines in your playbook

- stat: path=/path/to/file
  register: st

- debug: var=st
answered Feb 4, 2019 by Diana

Related Questions In Ansible

0 votes
1 answer

Return values of Ansible Commands

Hey @Rani, you could try something like ...READ MORE

answered Apr 2, 2019 in Ansible by Alia
645 views
0 votes
1 answer

stopping different hosts from reading the same value when usign ansible in loop

Try using this. Create a new directory ...READ MORE

answered Jul 27, 2018 in Ansible by DareDev
• 6,890 points
518 views
0 votes
1 answer

Is it possible to run commands on ansible host?

If you just trying to run a ...READ MORE

answered Jan 10, 2019 in Ansible by Vijay
1,248 views
0 votes
1 answer

How do I get an ENV variable and store it into a local variable - Ansible

Hey @Ninja, that is possible. What you ...READ MORE

answered Jan 24, 2019 in Ansible by Thomas
2,005 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
3,520 views
+2 votes
1 answer
0 votes
1 answer

Run Ansible adhoc commands in sequence

Hey @Thomas, by default ansible runs these ...READ MORE

answered Jan 14, 2019 in Ansible by Barbara
1,358 views
0 votes
1 answer

Execute shell commands using Ansible

You can use a playbook for this ...READ MORE

answered Jan 24, 2019 in Ansible by Ayaan
5,148 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP