5862 Commits

Author SHA1 Message Date
Wilken Rivera
a1d69bfe91 Fix liniting issues 2020-10-23 13:52:05 -04:00
Wilken Rivera
afd33679f5 builder/azure_arm: Fix build failures due to the deletion of attached managed disks
Previously (prior to v1.6.2) the Azure ARM builder had two delete functions
one that would run before any of the StepDelete* types, and one on deployment template
cleanup. The refactored coded re-introduces the logic from the previously removed
step in v1.6.1 as the main delete logic for the whole deployment
template. Ensuring that all deployed items are deleted before trying to
remove any managed disks.

This change moves all the deletion logic into the
step_deployment_template#Cleanup function to ensure that dependent steps
are only called once the created deployment items (i.e
StepDelateAdditionalDisks) have been deleted.

Test results before change
```

    compute.DisksClient#Delete: Failure sending request: StatusCode=0 -- Original Error: autorest/azure: Service returned an error. Status=<nil> Code="OperationNotAllowed" Message="Disk pkrdd02e9rzzu5k-1 is attached to VM /subscriptions/1f90521a-24f6-4758-ac3d-88d869fb0bf5/resourceGroups/packer-acceptance-test/providers/Microsoft.Compute/virtualMachines/pkrvm02e9rzzu5k."
--- FAIL: TestBuilderAcc_ManagedDisk_Windows_Build_Resource_Group_Additional_Disk (454.00s)
FAIL
FAIL    github.com/hashicorp/packer/builder/azure/arm   454.008s

```

Test results after change
```
--- PASS: TestBuilderAcc_ManagedDisk_Windows_Build_Resource_Group_Additional_Disk (563.56s)

```

Closes #10070
2020-10-23 13:44:27 -04:00
Megan Marsh
8f67f939f9
Merge pull request #10158 from Direnol/yandex-add-support-iam-auth
Added support for IAM credential in the token field and YC_TOKEN env
2020-10-23 09:39:46 -07:00
Roman Mingazeev
75befba67e add more doc 2020-10-23 18:01:52 +03:00
Roman Mingazeev
60595ad522 remove extra log 2020-10-23 14:09:05 +03:00
Roman Mingazeev
72fe3bbc26
Update builder/yandex/access_config.go
Co-authored-by: GennadySpb <lipenkov@gmail.com>
2020-10-23 14:05:39 +03:00
Roman Mingazeev
ae7fc84557 Added support for IAM credential in the token field and YC_TOKEN env 2020-10-23 11:47:28 +03:00
Megan Marsh
7fac596b37 don't try to delete a cd file if the upload of the cd itself failed 2020-10-22 16:53:40 -07:00
Megan Marsh
3be53e10af
Merge pull request #10128 from nayyara-samuel/add-state-timeout-linode
Add documented `state_timeout` parameters to Linode builder
2020-10-22 15:13:59 -07:00
Megan Marsh
c4001734d0
Merge pull request #10143 from hashicorp/do_9951
builder/vsphere: skip iso download if hashed file is already present on remote datastore
2020-10-22 15:06:04 -07:00
Megan Marsh
00037d8e69
Merge pull request #10145 from hashicorp/fix_10135
commhostport isn't present if communicator is null; protect casting i…
2020-10-22 14:24:23 -07:00
Megan Marsh
70cb4097e1 review comments, add plugin type for a few missing builders 2020-10-21 16:17:32 -07:00
Megan Marsh
c0ce8a9414 rework fixer deprecation code so we know what plugins they relate to 2020-10-21 15:28:59 -07:00
Megan Marsh
f1f834b8fe commhostport isn't present if communicator is null; protect casting in a check 2020-10-21 14:30:23 -07:00
Nahum Shalman
83a672f2c9 amazon/ebssurrogate: apply snapshot tags right when taking snapshot 2020-10-21 16:17:37 -04:00
Megan Marsh
796c40f89b builder/vsphere: skip iso download if hashed file is already present in remote packer_cache 2020-10-21 11:33:43 -07:00
Wilken Rivera
a2ba700ac0 Remove deprecated object ids from configs 2020-10-21 13:56:22 -04:00
Adrien Delorme
522d122858 regen all code 2020-10-21 12:04:10 +02:00
Adrien Delorme
4aea2efd0f HCL2: fully name SSHTemporaryKeyPair fields so that they don't conflict and can be generated 2020-10-21 11:53:07 +02:00
Wilken Rivera
1621ab59d8
tests/azure/arm: Update test image name (#10133)
I've run into a few cases where running the full test suite for the ARM
builder would fail because of conflicting image names. This is a
workaround for now the bigger fix is to have the acceptance clean up any
created images.

Results before change
```
the managed image named testBuilderAccManagedDiskWindows-1603151855 already exists in the resource group packer-acceptance-test, use the -force option to automatically delete it.
--- FAIL: TestBuilderAcc_ManagedDisk_Windows_Build_Resource_Group (0.66s)
```

Results after change
```
PASS
ok      github.com/hashicorp/packer/builder/azure/arm   2431.115s

```
2020-10-21 11:12:50 +02:00
Megan Marsh
799c548c40
Merge pull request #10116 from OblateSpheroid/GH8915
Feat (builder/oracle-oci): Allow filtering on base image
2020-10-20 14:41:09 -07:00
Adrien Delorme
d1e0214bec avoid panic debugging ssh key 2020-10-20 16:59:46 +02:00
Adrien Delorme
f51b231c17 Merge remote-tracking branch 'origin/master' into azr_selectable_temp_keygen_type_gcp 2020-10-20 16:39:01 +02:00
Adrien Delorme
536421efaf debug mode: don't dump the ssh key if its from a file 2020-10-20 12:00:49 +02:00
js-g
2f26e6d823 tests (builder/oracle-oci): test base image filter in config 2020-10-19 23:30:46 -04:00
Nayyara Samuel
32ebabfcf5 Add documented state_timeout parameters to Linode builder 2020-10-19 22:07:22 -04:00
Megan Marsh
b8e6e2c081
Merge pull request #10085 from 10000coins/f-aws-tenancy
builder/amazon: Support for source instance tenancy
2020-10-19 12:49:07 -07:00
Megan Marsh
ef1b401a22
Merge pull request #10102 from mattr-/update-amazon-builder-for-io2
builder/amazon: Add io2 as a supported volume type
2020-10-16 16:32:57 -07:00
Bryan Hundven
ecc8c6a44a Replace create_image with skip_create_image, as requested
Closes #9965
2020-10-16 15:42:30 -07:00
Bryan Hundven
476eefa26b Add 'create_image' option to googlecompute
When building a CI/CD deployment, during the PR process it's nice to be
able to run the builder, but not create the image the build produces.

Closes #9965
2020-10-16 15:42:17 -07:00
Megan Marsh
456214eb51
Merge pull request #10056 from marinsalinas/new_client
New official Outscale SDK migration.
2020-10-16 15:28:54 -07:00
Evan Pipho
608307cd1e Re-allow spot + tenancy. Validate tenancy is set to a usable value 2020-10-16 21:43:22 +00:00
Evan Pipho
d5d1a8708e Add tests for Tenancy vs Spot Price 2020-10-16 21:43:22 +00:00
Evan Pipho
6967e02103 Add support for source instance tenancy to amazon builders 2020-10-16 21:43:22 +00:00
js-g
0c34d6ca12 feat (builder/oracle-oci): add regex search on base image name 2020-10-15 15:28:38 -04:00
js-g
27128dc62f feat (builder/oracle-oci): allow filtering on base image 2020-10-15 11:02:16 -04:00
Adrien Delorme
54032d6c11 gen code and docs 2020-10-15 16:51:23 +02:00
Adrien Delorme
f4f731b83c Refactor google compute's temporary ssh keygen genertion to use the sshkey package 2020-10-15 16:51:11 +02:00
Matt Rogers
15f97421e2
builder/amazon: Add io2 as a supported volume type
io2 volumes are new as of 2020-08-24. This adds support for specifying
them in a packer template and having the iops value specified take
effect.
2020-10-14 09:01:17 -05:00
Wilken Rivera
c7ba5c9a14
Fix line ending issues for test files (#10096) 2020-10-14 11:03:43 +02:00
Marin Salinas
22a49a2f2e chore: fix test 2020-10-13 16:19:15 -05:00
Marin Salinas
472b008a94 chore: fix test 2020-10-13 15:16:01 -05:00
Megan Marsh
4810a3d86f
Merge pull request #10077 from hashicorp/document_3348
builder/qemu: docs: users must re-apply packer defaults for drive and device arguments
2020-10-13 11:41:28 -07:00
Marin Salinas
2578bbbb50 chore: fix test 2020-10-13 12:54:25 -05:00
Marin Salinas
09f57537bf chore: fix lint issues on osc builder 2020-10-13 11:02:13 -05:00
Marin Salinas
56807553fc chore: fix lint issues on osc builder 2020-10-13 10:45:32 -05:00
Jeff Wong
0f12414126
Merge branch 'master' into add-proxmox-vm-clone 2020-10-12 10:48:15 -07:00
Megan Marsh
01ed398756
fix up alicloud docs to make it clearer that disk_size and other disk device options are not top level fields. (#10080) 2020-10-12 10:28:25 +02:00
Jeff Wong
2861ad9074
clean up imports 2020-10-11 11:47:02 -07:00
Megan Marsh
709a173060 fix docs linking issue 2020-10-09 14:01:21 -07:00