Hello fellas. 

I'm new 'bout Ansible and English as well

I'v tried to use var_prompt module in my yml file. 

and now i am stuck by it.

I wanna show my remote's ip address when my prompt is shown up

but as far as i know, i can't use vars_prompt with task.

This is my yml as below.

###########################################################
---
- hosts: all
  remote_user: root

  vars_prompt:
      - name: "check_it"
        prompt: "Are you sure that you wanna update it? '{{ansible_host}}' "
        default: "Default is 'no'"
        private: no

  tasks:
     - include: "./vios.yml"
       when: check_it == "yes" 

###############################################################

and what i want to is 
##########################################################
---
- hosts: all
  remote_user: root

  tasks:
    
  vars_prompt:
      - name: "check_it"
        prompt: "Are you sure that you wanna update it? '{{ansible_host}}' "
        default: "Default is 'no'"
        private: no

     - include: "./vios.yml"
       when: check_it == "yes" 
#######################################################

is there any solution or search keyword? thank you all

-- 
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/92fc6c34-67f8-4de8-8f83-ee5ae291fd93%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to