Re: [ansible-project] Re: Unable to run playbook (Syntax Error)
so from emai (not a good source) the indentations were off in many places, this is a 'fixed' version of your play: - name: get version hosts: all gather_facts: false connection: local tasks: - name: run multiple commands on remote nodes ios_command: commands: - show version - show ip int brief register: print_output - debug: var=print_output.stdout_lines -- Brian Coca -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CACVha7d3aix9jQG0OH1LTMf83Quw4Z03UFjAogTZmorJ3hG6Tg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: Unable to run playbook (Syntax Error)
Tried it without the register and still no go! --- - name: get version hosts: all gather_facts: false connection: local tasks: - name: run multiple commands on remote nodes ios_command: commands: - show version - show ip int brief On Monday, April 30, 2018 at 5:26:30 PM UTC-4, Joshua Hill wrote: > > Can someone show me where my mistakes are with the below playbook? When i > try to run this playbook it tells me it fails at > > - name: run multiple commands on remote nodes > ^ here > > --- > - name: get version > hosts: all > gather_facts: false > connection: local > > tasks: >- name: run multiple commands on remote nodes > ios_command: >commands: > - show version > - show ip int brief > > register: print_output > > - debug: var=print_output.stdout_lines > > > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/d671cbf4-2caf-4dff-8718-966353155c47%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [ansible-project] Re: Unable to run playbook (Syntax Error)
hosts/name order does not matter, indentation does seem to be off, - debug should start at same level as the previous task -- -- Brian Coca -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CACVha7eYr8ECutVJiN78gH6EEQF5DwRtMd_fP34kipfvcjQMcQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: Unable to run playbook (Syntax Error)
Same issue On Monday, April 30, 2018 at 5:26:30 PM UTC-4, Joshua Hill wrote: > > Can someone show me where my mistakes are with the below playbook? When i > try to run this playbook it tells me it fails at > > - name: run multiple commands on remote nodes > ^ here > > --- > - name: get version > hosts: all > gather_facts: false > connection: local > > tasks: >- name: run multiple commands on remote nodes > ios_command: >commands: > - show version > - show ip int brief > > register: print_output > > - debug: var=print_output.stdout_lines > > > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/8ac41e67-a42b-4a28-acb2-9078a356e3bf%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.