I'm using packer to build out Windows AMIs. It works great up until the point that I need to download a file from an S3 bucket using powershell. When the powershell script is run it can't seem to connect to the bucket. I'm providing the script the proper bucket name, keys, etc.. and it's using the correct region for my credentials and for the bucket and yet I still get the following errors.
VERBOSE: Invoking Amazon S3 object download APIs in region 'eu-west-1'
Read-S3Object : Name resolution failure attempting to reach service in region
eu-west-1 (as supplied to the -Region parameter or from configured shell default)
Unable to connect to the remote server
amazon-ebs: Possible causes:
amazon-ebs: - The region may be incorrectly specified (did you specify an availability
amazon-ebs: zone?).
amazon-ebs: - The service may not be available in the region.
amazon-ebs: - No network connectivity.
Since it says a possible cause is no network connectivity is it possible the gateway or nic for the builder isn't functioning properly. If so, is that something that can be fixed from the script itself? I don't have this issue using a different AWS account but with the same Bucket roles and rules.
Thanks!