[Agent] EC2 Agent has no internet access (VPN)

Hi experts,

When launching ec2-instances in VPN they have no internet access when they have no public ip (not elastic ip!).

The run-instances command has an option --associate-public-ip-address which allocates one, and allows internet access e.g. maven-repo read.


Currently the agent-cloud configuration of TC does not allow the property to be set.

Is anybody running ec2-agents in a VPC with access to the internet?


1 comment
Comment actions Permalink

i will answer my own question ...

There is an option in the subnet to auto-assign public ip, which since a few weeks can changed too.

You can now configure any subnet in your account to automatically assign a public IP address to instances launched into that subnet. Previously, only default subnets in a default VPC had this capability.
To set the flag, go to the VPC console, click Subnets, and then right-click your subnet and select “Modify Auto-Assign Public IP”. In the dialog box, select the “Enable auto assign public IP” check box to enable this attribute. To disable this attribute, clear the check box. This is also available for users over the EC2 command line interface (EC2 CLI). To learn more, see Modifying Your Subnet’s Public IP Addressing Behavior in the VPC documentation.


Please sign in to leave a comment.