I am trying to dynamically set my target host info, which I can only get to 
through a Bastion host.  Here is what I am doing:

  - name: Set up host
    lineinfile:
  path: "{{ inventory_file }}"
  regexp: '^ansible_ssh_common_args=-o ProxyCommand="ssh -p BASTION_port -W 
%h:%p -q BASTION_user@BASTION_IP"'
  line: '^ansible_ssh_common_args=-o ProxyCommand="ssh -p {{ new_ssh_port 
}} -W %h:%p -q {{ ansible_user }}@{{ ansible_default_ipv4.address }}"'
  
I get this error: 
                   /work/hosts does not exists. 

The file does exist, in that directory. I've tried chmod'ing /work/hosts to 
777 which did not help. Can anyone see what I am doing wrong? Why is it not 
finding a file that is there?

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/f11aee14-98b4-48bd-8451-f08e8716f844n%40googlegroups.com.

Reply via email to