On Tue, Jan 12, 2016 at 5:37 PM, Colin Byrne <[email protected]> wrote: > Hey, > > So I would love to get the aws ec2 inventory working, but I cant seem to > find a way to connect to my instances within a VPC subnet. > > I changed the ec2.ini configuration to: > > destination_variable = private_dns_name
This options makes the returned address of an instance to be an internal IP in the IP range of the subnet. Unless you are also running ansible from an instance inside the same subnet (or in one which can communicate with it), it won't work. If you set this variable to 'public_dns_name' or 'ip_address' it should enable you to access the instances (given that you have the SSH port unblocked in the instance's security group). Or you could use the SSH config's option 'ProxyCommand' to proxy the connection through a gateway, but personally I think this later is not worth the effort (unless you're configuring a private subnet). -- Ivan Sichmann Freitas -- 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/CAG2tFJxHxkSv4kVJOUWhsxiH91cn3OayE7H9RuQDs_ry1uEDvw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
