I am trying to figure out why my variable is not defined and have not been 
able to find any solutions online.
Can anyone help?


test.yml
---
- name: Test playbook
  hosts: localhost
  connection: local
  vars: 
      test: hello

  tasks:
     - name: test var
       debug:
           msg: "{{ test}}"
       register: test_out
       debug:
           var: test_out

output from playbook:
PLAY [Test playbook] 
***********************************************************************************************************************************************************************************

TASK [Gathering Facts] 
*********************************************************************************************************************************************************************************
ok: [localhost]

TASK [test var] 
****************************************************************************************************************************************************************************************
ok: [localhost] => {
    "test_out": "VARIABLE IS NOT DEFINED!"
}

PLAY RECAP 
*********************************************************************************************************************************************************************************************
localhost                  : ok=2    changed=0    unreachable=0    failed=0

-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/190f4578-f957-4215-b3fd-728af599a1df%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to