We can't tag on instance creation when we're in "restricted" regions,
so let's add the tags after the resources have been created.
Adds methods to AccessConfig to detect if we're in China or US Gov
regions (i.e. "restricted").
Also turns tag:tag maps into a type, and moves methods around validating
and converting them to ec2Tags to methods of the type.
Run now takes a context as well as a statebag. We'll assign the context
to the blank identifier to prevent namespace collisions. We'll let the
step authors opt-in to using the context.
`find . -iname "step_*.go" -exec gsed -i'' 's/func \(.*\)Run(/func \1Run(_ context.Context, /' {} \;`
This commit adds a change which ensures that the Session Token
config struct item is removed from log output.
Signed-off-by: Krzysztof Wilczynski <kw@linux.com>
StepTagEBSVolumes is no longer needed, since this functionality is now
taken over by StepRunSourceInstance and StepRunSpotInstance. So remove
this functionality from the codebase.
In AWS we can derive the `VpcId` and AZ from the `SubnetId`, so now we do. In the config you can now only specify the `SubnetId`.
This fixes issue #4693.
Set SriovNetSupport to "simple". As of February 2017, this applies to C3, C4,
D2, I2, R3, and M4 (excluding m4.16xlarge).
Set EnaSupport to true. As of February 2017, this applies to C5, I3, P2, R4,
X1, and m4.16xlarge.
This PR adds the ability for Packer to clean up snapshots in addition to
deregistering AMIs at build time.
To test this, I used the following `test.json` file:
```json
{
"builders": [
{
"type": "amazon-ebs",
"region": "us-east-1",
"source_ami": "ami-fce3c696",
"ami_name": "packer-test",
"instance_type": "m3.medium",
"ssh_username": "ubuntu",
"vpc_id": "some-vpc-id",
"subnet_id": "some-subnet-routed-through-igw",
"security_group_id": "some-security-group-with-port-22-access",
"force_delete_snapshot": true
}
],
"provisioners": [
{
"type": "shell-local",
"command": "echo 'hello'"
}
]
}
```
I appreciate any constructive feedbakc that can be given. Cheers!
This commit adds the ability to configure unique tags on snapshots
that are separate from the tags defined on the AMI. Anything applied
to the AMI will also be applied to the snapshots, but `snapshot_tags`
will override and append tags to the tags already applied to the snapshots