Commit Graph

4363 Commits

Author SHA1 Message Date
James Nugent 51af5e793d Merge pull request #7294 from hashicorp/import-aws-iampp
provider/aws: Support Import for `aws_iam_account_password_policy`
2016-06-24 14:44:36 +03:00
James Nugent b1e933385b Merge pull request #7296 from hashicorp/import-aws-cloudwatcher
provider/aws: Support Import for `aws_cloudwatch_event_rule`
2016-06-24 14:44:17 +03:00
James Nugent c91e45604d Merge pull request #7295 from hashicorp/import-aws-cloudtrail
provider/aws: Support Import for `aws_cloudtrail`
2016-06-24 14:43:58 +03:00
James Nugent 790307aa7a Merge pull request #7307 from hashicorp/arm-nsg-polling
provider/azurerm: `azurerm_network_security_group` now polls for State succeeded
2016-06-24 14:29:47 +03:00
Joe Topjian 69743450d0 Merge pull request #7194 from scrossan/master
provider/openstack: Change rules type to List
2016-06-23 22:18:24 -06:00
stack72 804f5e1288 provider/azurerm: `azurerm_network_security_group` now polls for State
succeeded

This fixes #7122 where the SG was not fully configured before a
dependant service was created

```
make testacc TEST=./builtin/providers/azurerm
TESTARGS='-run=TestAccAzureRMNetworkSecurityGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/azurerm -v
-run=TestAccAzureRMNetworkSecurityGroup_ -timeout 120m
=== RUN   TestAccAzureRMNetworkSecurityGroup_basic
--- PASS: TestAccAzureRMNetworkSecurityGroup_basic (128.93s)
=== RUN   TestAccAzureRMNetworkSecurityGroup_withTags
--- PASS: TestAccAzureRMNetworkSecurityGroup_withTags (164.52s)
=== RUN   TestAccAzureRMNetworkSecurityGroup_addingExtraRules
--- PASS: TestAccAzureRMNetworkSecurityGroup_addingExtraRules (178.20s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/azurerm
471.677s
```
2016-06-23 23:32:34 +01:00
Joe Topjian 5ce693df99 Merge pull request #7184 from alkersan/openstack_stop_before_detele
provider/openstack stop before destroy
2016-06-23 08:15:08 -06:00
stack72 af44dbd3cd provider/aws: Support Import for `aws_cloudwatch_event_rule`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSCloudWatchEventRule_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSCloudWatchEventRule_ -timeout 120m
=== RUN   TestAccAWSCloudWatchEventRule_importBasic
--- PASS: TestAccAWSCloudWatchEventRule_importBasic (20.15s)
=== RUN   TestAccAWSCloudWatchEventRule_basic
--- PASS: TestAccAWSCloudWatchEventRule_basic (35.25s)
=== RUN   TestAccAWSCloudWatchEventRule_full
--- PASS: TestAccAWSCloudWatchEventRule_full (19.43s)
=== RUN   TestAccAWSCloudWatchEventRule_enable
--- PASS: TestAccAWSCloudWatchEventRule_enable (50.52s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    125.380s
```
2016-06-23 10:31:40 +01:00
stack72 b2f0b2c912 provider/aws: Support Import for `aws_cloudtrail`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSCloudTrail_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSCloudTrail_
-timeout 120m
=== RUN   TestAccAWSCloudTrail_importBasic
--- PASS: TestAccAWSCloudTrail_importBasic (64.64s)
=== RUN   TestAccAWSCloudTrail_basic
--- PASS: TestAccAWSCloudTrail_basic (97.96s)
=== RUN   TestAccAWSCloudTrail_enable_logging
--- PASS: TestAccAWSCloudTrail_enable_logging (137.07s)
=== RUN   TestAccAWSCloudTrail_is_multi_region
--- PASS: TestAccAWSCloudTrail_is_multi_region (138.51s)
=== RUN   TestAccAWSCloudTrail_logValidation
--- PASS: TestAccAWSCloudTrail_logValidation (102.61s)
=== RUN   TestAccAWSCloudTrail_tags
--- PASS: TestAccAWSCloudTrail_tags (135.66s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    676.484s
```
2016-06-23 10:18:24 +01:00
stack72 20bc268d34 provider/aws: Support Import for `aws_iam_account_password_policy`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSIAMAccountPasswordPolicy_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSIAMAccountPasswordPolicy_ -timeout 120m
=== RUN   TestAccAWSIAMAccountPasswordPolicy_importBasic
--- PASS: TestAccAWSIAMAccountPasswordPolicy_importBasic (14.75s)
=== RUN   TestAccAWSIAMAccountPasswordPolicy_basic
--- PASS: TestAccAWSIAMAccountPasswordPolicy_basic (26.06s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    40.831s
```
2016-06-23 09:52:45 +01:00
James Nugent d39760e620 Merge pull request #7281 from hashicorp/import-aws-ecr
provider/aws: Support import functionality for `aws_ecr_repository`
2016-06-23 11:09:09 +03:00
James Nugent df46af5b57 Merge pull request #7278 from hashicorp/vsphere-vm-migration
provider/vsphere: Add migration for `enable_disk_uuid` on `virtual_machine`
2016-06-23 11:03:58 +03:00
James Nugent c9a4f84caa Merge pull request #7282 from hashicorp/import-aws-vpngateway
provider/aws: Support Import for `aws_vpn_gateway`
2016-06-23 10:52:58 +03:00
James Nugent 1bbb75bc9a Merge pull request #7284 from hashicorp/import-aws-cwlg
provider/aws: Add Import support for `aws_cloudwatch_log_group`
2016-06-23 10:52:32 +03:00
James Nugent 73b823ba47 Merge pull request #7285 from hashicorp/import-aws-ecsng
provider/aws: Support Import for `aws_elasticache_subnet_group`
2016-06-23 10:52:21 +03:00
James Nugent a6ae8eaac8 Merge pull request #7286 from hashicorp/import-aws-dbsng
provider/aws: Support Import functionality for `aws_db_subnet_group`
2016-06-23 10:52:04 +03:00
James Nugent b13ef7c748 Merge pull request #7287 from hashicorp/import-aws-snstopic
provider/aws: Support Import for `aws_sns_topic`
2016-06-23 10:51:42 +03:00
James Nugent 5043114d33 Merge pull request #7288 from hashicorp/import-aws-redshiftsng
provider/aws: Support Import for `aws_redshift_subnet_group`
2016-06-23 10:51:20 +03:00
James Nugent eefd2d5a7c Merge pull request #7289 from hashicorp/import-aws-vpcendpoint
provider/aws: Support Import for `aws_vpc_endpoint`
2016-06-23 10:50:55 +03:00
James Nugent d669077a23 Merge pull request #7290 from hashicorp/import-aws-iamuser
provider/aws: Support Import for `aws_iam_user`
2016-06-23 10:50:19 +03:00
James Nugent 5ac9f21d2f Merge pull request #7291 from hashicorp/import-aws-iamgroup
provider/aws: Support Import for `aws_iam_group`
2016-06-23 10:49:14 +03:00
stack72 86fcabc651 provider/aws: Changing test parameters to be us-west-2 based 2016-06-23 08:13:49 +01:00
stack72 2488bf2a2e Merge branch 'keshav-hashicorp-rebase' of https://github.com/Yelp/terraform into Yelp-keshav-hashicorp-rebase 2016-06-23 07:53:54 +01:00
dkalleg 81673a27e7 Graceful read miss (#7220)
For both the file and virtual_disk resource, Stat is used during read,
but if Stat returns an error, read() will return that error. In doing
so, if a resource is deleted manually, the TF user would then not be
able to destroy the resource because the read would block the Delete()
call. With this patch, read() will only return an error if that error
is NOT a DatastoreNoSuchFileError.
2016-06-23 07:47:08 +01:00
Dmytro Aleksandrov c32d152495 Implemented stop_before_destroy behavior
Docs and acceptance test included
2016-06-23 09:20:41 +03:00
stack72 ba5131b7d7 provider/aws: Support Import for `aws_iam_group`
Small change to the test as it was failing sometimes as it was using the
same identifier. The small change has made it more stable when running
it in quick succession as it isn't an update

```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSIAMGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSIAMGroup_
-timeout 120m
=== RUN   TestAccAWSIAMGroup_importBasic
--- PASS: TestAccAWSIAMGroup_importBasic (14.14s)
=== RUN   TestAccAWSIAMGroup_basic
--- PASS: TestAccAWSIAMGroup_basic (22.88s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    37.040s
```
2016-06-23 03:10:31 +01:00
stack72 82529f8029 provider/aws: Support Import for `aws_iam_user`
The Id wasn't being set until after the Read func returned from the API.
I needed to move that Id set up until just after the Create response
returned

The same Id's have been set - username

```
make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSUser_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSUser_
-timeout 120m
=== RUN   TestAccAWSUser_importBasic
--- PASS: TestAccAWSUser_importBasic (14.24s)
=== RUN   TestAccAWSUser_basic
--- PASS: TestAccAWSUser_basic (24.99s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    39.261s
```
2016-06-23 02:56:59 +01:00
stack72 3332f757cb provider/aws: Support Import for `aws_vpc_endpoint`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSVpcEndpoint_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSVpcEndpoint_
-timeout 120m
=== RUN   TestAccAWSVpcEndpoint_importBasic
--- PASS: TestAccAWSVpcEndpoint_importBasic (45.90s)
=== RUN   TestAccAWSVpcEndpoint_basic
--- PASS: TestAccAWSVpcEndpoint_basic (46.64s)
=== RUN   TestAccAWSVpcEndpoint_withRouteTableAndPolicy
--- PASS: TestAccAWSVpcEndpoint_withRouteTableAndPolicy (91.91s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    184.470s
```
2016-06-23 02:48:59 +01:00
stack72 45f394b5ae provider/aws: Support Import for `aws_redshift_subnet_group`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSRedshiftSubnetGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSRedshiftSubnetGroup_ -timeout 120m
=== RUN   TestAccAWSRedshiftSubnetGroup_importBasic
--- PASS: TestAccAWSRedshiftSubnetGroup_importBasic (47.76s)
=== RUN   TestAccAWSRedshiftSubnetGroup_basic
--- PASS: TestAccAWSRedshiftSubnetGroup_basic (47.75s)
=== RUN   TestAccAWSRedshiftSubnetGroup_updateSubnetIds
--- PASS: TestAccAWSRedshiftSubnetGroup_updateSubnetIds (77.74s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    173.271s
```
2016-06-23 02:33:29 +01:00
stack72 b310842383 provider/aws: Support Import for `aws_sns_topic`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSSNSTopic_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSSNSTopic_
-timeout 120m
=== RUN   TestAccAWSSNSTopic_importBasic
--- PASS: TestAccAWSSNSTopic_importBasic (17.02s)
=== RUN   TestAccAWSSNSTopic_basic
--- PASS: TestAccAWSSNSTopic_basic (16.59s)
=== RUN   TestAccAWSSNSTopic_withIAMRole
--- PASS: TestAccAWSSNSTopic_withIAMRole (28.90s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    62.536s
```
2016-06-23 02:27:13 +01:00
stack72 95476404c3 provider/aws: Support Import functionality for `aws_db_subnet_group`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSDBSubnetGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSDBSubnetGroup_ -timeout 120m
=== RUN   TestAccAWSDBSubnetGroup_importBasic
--- PASS: TestAccAWSDBSubnetGroup_importBasic (53.80s)
=== RUN   TestAccAWSDBSubnetGroup_basic
--- PASS: TestAccAWSDBSubnetGroup_basic (52.29s)
=== RUN   TestAccAWSDBSubnetGroup_withUndocumentedCharacters
--- PASS: TestAccAWSDBSubnetGroup_withUndocumentedCharacters (54.63s)
=== RUN   TestAccAWSDBSubnetGroup_updateDescription
--- PASS: TestAccAWSDBSubnetGroup_updateDescription (83.04s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    243.785s
```
2016-06-23 02:21:11 +01:00
stack72 2a07f86041 provider/aws: Support Import for `aws_elasticache_subnet_group`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSElasticacheSubnetGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSElasticacheSubnetGroup_ -timeout 120m
=== RUN   TestAccAWSElasticacheSubnetGroup_importBasic
--- PASS: TestAccAWSElasticacheSubnetGroup_importBasic (46.80s)
=== RUN   TestAccAWSElasticacheSubnetGroup_basic
--- PASS: TestAccAWSElasticacheSubnetGroup_basic (48.79s)
=== RUN   TestAccAWSElasticacheSubnetGroup_update
--- PASS: TestAccAWSElasticacheSubnetGroup_update (76.81s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    172.431s
```
2016-06-23 02:12:02 +01:00
stack72 24a21e2f0a provider/aws: Add Import support for `aws_cloudwatch_log_group`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSCloudWatchLogGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSCloudWatchLogGroup_ -timeout 120m
=== RUN   TestAccAWSCloudWatchLogGroup_importBasic
--- PASS: TestAccAWSCloudWatchLogGroup_importBasic (17.24s)
=== RUN   TestAccAWSCloudWatchLogGroup_basic
--- PASS: TestAccAWSCloudWatchLogGroup_basic (16.69s)
=== RUN   TestAccAWSCloudWatchLogGroup_retentionPolicy
--- PASS: TestAccAWSCloudWatchLogGroup_retentionPolicy (29.10s)
=== RUN   TestAccAWSCloudWatchLogGroup_multiple
--- PASS: TestAccAWSCloudWatchLogGroup_multiple (22.09s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    85.140s
```
2016-06-23 01:55:29 +01:00
stack72 882e4fe770 provider/aws: Support Import for `aws_vpn_gateway`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSVpnGateway_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSVpnGateway_
-timeout 120m
=== RUN   TestAccAWSVpnGateway_importBasic
--- PASS: TestAccAWSVpnGateway_importBasic (48.29s)
=== RUN   TestAccAWSVpnGateway_basic
--- PASS: TestAccAWSVpnGateway_basic (86.98s)
=== RUN   TestAccAWSVpnGateway_reattach
--- PASS: TestAccAWSVpnGateway_reattach (97.93s)
=== RUN   TestAccAWSVpnGateway_delete
--- PASS: TestAccAWSVpnGateway_delete (65.61s)
=== RUN   TestAccAWSVpnGateway_tags
--- PASS: TestAccAWSVpnGateway_tags (73.81s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    372.624s
```
2016-06-23 01:25:13 +01:00
stack72 edf593febd provider/aws: Support import functionality for `aws_ecr_repository`
Changes required:

* ECR Read func doesn't need to take ``registry_id` as it uses the
  current account Id
* `name` wasn't being set in the ECR Read so the import was failing as
  name wasn't found

```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSEcrRepository_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSEcrRepository_ -timeout 120m
=== RUN   TestAccAWSEcrRepository_importBasic
--- PASS: TestAccAWSEcrRepository_importBasic (17.37s)
=== RUN   TestAccAWSEcrRepository_basic
--- PASS: TestAccAWSEcrRepository_basic (16.05s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    33.437s
```
2016-06-23 00:58:59 +01:00
stack72 74ea8697de provider/vsphere: Add migration for `enable_disk_uuid` on
`virtual_machine`

Fixes #7275 - a state migration was missed when `enable_disk_uuid` was
merged

```
make testacc TEST=./builtin/providers/vsphere
TESTARGS='-run=TestVSphereVirtualMachineMigrateState'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/vsphere -v
-run=TestVSphereVirtualMachineMigrateState -timeout 120m
=== RUN   TestVSphereVirtualMachineMigrateState
--- PASS: TestVSphereVirtualMachineMigrateState (0.00s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/vsphere
0.018s
```
2016-06-22 23:43:44 +01:00
Keshav Varma 58bd6dfb02 Add an AWS Spot fleet resource 2016-06-21 17:31:30 -07:00
Clint f4a1833baf provider/aws: Bundle IOPs and Allocated Storage update for DB Instances (#7203) 2016-06-21 14:53:13 -05:00
clint shryock 005d9a12e0 provider/aws: Update IAM / ELB server certs from expired ones 2016-06-21 13:54:40 -05:00
Radek Simko 6fed5eb8f0 aws: Use new STS endpoint to validate creds (#6536) 2016-06-20 23:14:07 +01:00
David Harris c7eb8a2022 provider/aws: elastic beanstalk invalid setting crash (#7222)
* Only check the `cnamePrefix` if the CNAME is not nil

* Get Elastic Beanstalk error messages
2016-06-20 16:21:15 -05:00
clint shryock ecc455ebb4 provider/aws: Guard against nil values in EC2 Tags 2016-06-20 15:53:04 -05:00
David Tolnay 0b9fb1d8f8
Stop swallowing errors from DescribeAlarms
This caused alarms to be created repeatedly if Terraform is running without
DescribeAlarms permission.
2016-06-18 15:57:52 -07:00
James Bardin 2a2f7cbc52 Merge pull request #7205 from hashicorp/jbardin/GH-2027
core: don't check any parts of a computed set in InstanceDiff.Same
2016-06-17 11:00:29 -04:00
Radek Simko 2cdb5a367e aws/route53_zone: Make delegation_set_id conflict w/ vpc_id (#7213)
- as per the API reference it is not possible to use delegation sets w/ private hosted zones
   - http://docs.aws.amazon.com/Route53/latest/APIReference/API-create-hosted-zone-private.html
   - http://docs.aws.amazon.com/Route53/latest/APIReference/API_CreateHostedZone.html
 - if you specify both AWS returns confusing error "InvalidInput" with no further details so this should reduce potential confusions & improve UX
2016-06-17 12:35:49 +01:00
stack72 7b482cca9b provider/mysql: Empty Provider Credentials Caused Panic
There are currently no checks on username and endpoint in the provider
schema from being an empty value. This PR adds support to make sure that
endpoint and username are not empty strings as that can cause a panic

Results of the PR:

```
 % terraform apply
There are warnings and/or errors related to your configuration. Please
fix these before continuing.

Errors:

  * provider.mysql: Endpoint must not be an empty string
```
2016-06-17 11:32:30 +01:00
James Bardin a3e2c99219 Add a failing acceptance test from GH-2027 2016-06-16 18:43:15 -04:00
James Bardin f65a898a51 Merge pull request #7188 from hashicorp/jbardin/GH-7017
provider/aws: Check for unassigned AWS Cookie Stickiness Policy
2016-06-16 11:35:05 -04:00
Clint 24bcac42be provider/aws: Retry EIP association (#7186) 2016-06-16 10:03:16 -05:00
James Bardin cfd8254db8 Check for existing but unassigned LB policies
If an AWS Cookie Stickiness Policy is removed from the listener in
the AWS console the policy isn't deleted. Cross reference the policy
name with those assigned to the listener to determine if the policy
is actually being used.
2016-06-16 10:10:52 -04:00