Megan Marsh
340363a649
Merge pull request #6613 from hashicorp/merge_ssh_config_funcs
...
Merge ssh config funcs from builders
2018-08-23 16:03:36 -07:00
Adrien Delorme
41f6e0334d
refactor all copy pasted sshConfig with into communicator.Config.SSHConfigFunc
...
* still need to append the auth methods into an array for gracefullness
2018-08-22 17:02:23 +02:00
Megan Marsh
ff6a039d5b
replace scrubconfig with packer.LogSecretFilter.Set
...
filter winrm password from logs
Add new root-level packer template option, sensitive-variables, to tell us what user variables to mark sensitive.
2018-08-20 15:35:55 -07:00
James Nugent
9fffe4056e
Merge pull request #5452 from smaato/tag-spot-requests
...
Enable tagging of spot requests
2018-07-16 13:00:07 -05:00
Megan Marsh
f49a2d8aed
move UI call to before the wait; add context to these steps
2018-07-11 10:36:21 -07:00
Megan Marsh
cf63dd10bf
replace AMIStateRefreshFunc, InstanceStateRefreshFunc, our spot instance waiter, our chroot volume waiter, and our snapshot waiters with waiters form AWS's SDK.
2018-07-11 10:34:20 -07:00
Mark Meyer
3dbf1cb371
Enable tagging of spot requests
...
This adds a new parameter to the EBS builders named `spot_tags'. This
parameter accepts a map of tags, much like `tags'. These tags will be
applied to a spot request that is created.
Improve visibility.
2018-07-07 16:06:51 +02:00
DanHam
d5304a25e9
Pass T2 Unlimited settings to run instance step for appropriate EC2 builders
2018-05-15 12:25:06 +01:00
DanHam
9b6fc5a58d
Remove tmp files created by builder/amazon/instance tests
2018-04-30 18:16:46 +01:00
Megan Marsh
3afb243f11
use build name to ensure that winrm password and other shared state is not overwritten if two builders need the password in the same packer run.
2018-04-16 13:41:17 -07:00
Matthew Hooker
21812fa17f
Add volume and run tags if in us-gov/china
...
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.
2018-02-05 16:39:20 -08:00
Matthew Hooker
7a189a83a1
fix imports
...
`find . -type f -name '*.go' -not -path "./vendor/*" -exec goimports -w {} \;`
2018-01-24 17:09:17 -08:00
Matthew Hooker
a831d522be
change run signatures
...
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, /' {} \;`
2018-01-24 17:09:17 -08:00
Matthew Hooker
366dc3da0a
move multistep imports to helper.
...
gomvpkg -from "github.com/mitchellh/multistep" -to "github.com/hashicorp/packer/helper/multistep"
2018-01-24 17:09:15 -08:00
Matthew Hooker
ebe995c0ff
run goimports
2018-01-22 17:21:10 -08:00
Matthew Hooker
f3dea272d9
Set session in state bag
...
We can construct connections to arbitrary regions from it
2017-12-19 11:32:33 -08:00
Matthew Hooker
f6c401a143
don't pass in accessconfig
2017-12-19 11:32:32 -08:00
Rong Chen
3e92b1374e
issue5606: follow the convention to use AccessConfig to create new aws session for step_create_tags etc.
2017-12-19 10:34:12 -08:00
Rickard von Essen
63f791570a
Merge pull request #5665 from kwilczynski/remove-sts-token-from-logging
...
amazon: Remove Session Token (STS) from being shown in the log.
2017-12-10 06:50:42 +01:00
Matthew Hooker
f216330ba3
spot instance ena/sriov checking for all other builders
2017-12-08 14:56:19 -08:00
Krzysztof Wilczynski
05327b7524
amazon: Remove Session Token (STS) from being shown in the log.
...
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>
2017-12-04 22:14:38 +01:00
John Davies-Colley
707ec675b2
ssh interface for amazon builders 🔨
2017-11-22 15:49:38 +13:00
Matthew Hooker
8ab390a048
Merge pull request #5495 from smaato/master
...
Fix regressions relating to spot instances and EBS volumes
2017-11-02 08:53:27 -07:00
Matthew Hooker
c65fa8490d
fix various bugs deregistering AMIs
...
always deregister ami in session region
validate that session region does not appear in ami_regions
2017-10-30 14:17:19 -07:00
Mark Meyer
4c5df79222
Fix regressions introduced in the instance builder
...
Related to #5504
2017-10-24 23:23:18 +02:00
Matthew Hooker
f7e269945e
add cidr validation and rename option
2017-10-12 17:05:56 -07:00
Matthew Hooker
c74be87187
Merge pull request #5384 from dave2/sg-source-cidr
...
[WIP] Allow temporary security group to have source CIDR block explicit
2017-10-12 17:05:45 -07:00
SwampDragons
512ac214b4
Merge pull request #5417 from smaato/master
...
Add ability to tag volumes on creation
2017-10-12 12:56:25 -07:00
Mark Meyer
dbb3c76032
Remove redundant step and its usage
...
StepTagEBSVolumes is no longer needed, since this functionality is now
taken over by StepRunSourceInstance and StepRunSpotInstance. So remove
this functionality from the codebase.
2017-10-12 21:40:21 +02:00
Matthew Hooker
ae455bff99
add debugging help if ec2-upload-bundle fails
2017-10-05 17:33:07 -07:00
Mark Meyer
2661fd7869
Move building of spot instances into its own step
2017-10-04 12:38:21 +02:00
Zanetti, David
8a8b51be97
Allow temporary security group to have source CIDR block explicitly provided
2017-09-26 00:57:56 +00:00
Matthew Hooker
02cd6bc7f0
Merge pull request #5288 from hashicorp/fix3114
...
add token variable to upload bundle command template
2017-09-25 18:36:28 -05:00
Matthew Hooker
4bc8e7de3d
add token variable to upload bundle command template
2017-09-25 16:35:53 -07:00
Megan Marsh
2d4bc70d7b
use ami prefix to make it clear that these variables are amazon specific
...
add fixer, fixer tests
2017-08-28 11:21:27 -07:00
Megan Marsh
9e2e467b31
Allow granular modification of sriov and ena enhanced networking options in amazon amis. Maintain old functionality.
2017-08-25 14:49:53 -07:00
Megan Marsh
14b2d04332
make force_deregister work in all regions, not just original region.
2017-08-14 12:31:58 -07:00
Matthew Hooker
56c513088b
I think this was the intention
2017-06-09 10:34:49 -07:00
Megan Marsh
b8c2a5fd43
fix step initializer everywhere StepAMIRegionCopy is called
2017-06-01 09:28:17 -07:00
Paul Thrasher
0be5a28080
Fix issue 4693 - Derive vpc_id from subnet_id
...
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 .
2017-05-15 13:46:05 -07:00
Matthew Hooker
81522dced0
move packer to hashicorp
2017-04-04 13:39:01 -07:00
Matthew Hooker
50d9546658
builder/amazon: set force_deregister to true on -force
2017-03-09 14:24:49 -08:00
Aaron Stone
1cc3cdf7b5
Always set both SRIOV and ENA when Enhanced Networking is enabled
...
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.
2017-02-25 07:16:35 -08:00
Rickard von Essen
ba9cae5078
builder/amazon: Add SourceAMI and BuildRegion template
...
Added {{ .SourceAMI }} and {{ .BuildRegion }} template values availible
in `ami_description`, `run_tags`, `run_volume_tags`, `tags`, and
`snapshot_tags`.
2017-01-21 20:39:58 +01:00
Rickard von Essen
26fe9cf339
builder/amazon: Fix crash in amazon-instance
...
Closes #4360
2017-01-06 15:17:02 +01:00
Rickard von Essen
c3a352955e
amazon: Added snapshot_users and snapshot_groups
2016-12-04 16:03:01 +01:00
Matthew Hooker
832de2104b
Revert "Merge pull request #4230 from mitchellh/revert-4223-closes_3320"
...
This reverts commit bda89b0c42
, reversing
changes made to f9f9d82419
.
2016-11-30 13:28:34 -08:00
Matthew Hooker
f5c3c25d2b
Revert "Adds `force_delete_snapshot` flag"
2016-11-30 13:10:22 -08:00
Matthew Hooker
f9f9d82419
Merge pull request #4223 from artburkart/closes_3320
...
Adds `force_delete_snapshot` flag
2016-11-30 12:53:34 -08:00
Arthur Burkart
5b59f56cdb
Adds `force_delete_snapshot` flag
...
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!
2016-11-29 23:39:36 -05:00