Commit Graph

3755 Commits

Author SHA1 Message Date
Kit Ewbank 380aef9720 Tighten up documentation, same-account acceptance test, better error handling. 2017-02-02 18:46:23 -05:00
Jake Champlin 188a00cbe0 Merge pull request #11642 from hashicorp/f-improve-iam-tests
provider/aws: Improve IAM Group AccTests
2017-02-02 14:10:51 -05:00
Jake Champlin 643a52ab3e
provider/aws: Improve IAM Group AccTests
Improve the iam_group acceptance tests. Previously, the iam_group would overlap when running our tests in parallel. This fixes that.
2017-02-02 13:03:39 -05:00
Jake Champlin e4a36c3d7a
provider/aws: Better handle parallel tests spot-fleet-req
Better handle parallel testing of the `aws_spot_fleet_request` resource. Previously we were catching a lot of errors due to naming the policy_attachment resource the same between tests.
2017-02-02 12:48:52 -05:00
Clint aa7aa19592 Merge pull request #11637 from hashicorp/b-aws-test-fixes
provider/aws: More lambda test fixes
2017-02-02 10:30:23 -06:00
liamjbennett 4aa5117e82
New resource aws_codebuild_project 2017-02-02 16:13:51 +00:00
clint shryock 8cede07657 fix missing %s 2017-02-02 10:04:27 -06:00
clint shryock 27c1dd8097 provider/aws: More lambda test cleanups 2017-02-02 09:57:44 -06:00
Jake Champlin 755040b177 Merge pull request #11617 from hashicorp/f-tags-dynamodb
provider/aws: Add tag support to the dynamodb table resource
2017-02-02 09:44:54 -05:00
Jake Champlin dacc765a5e
update casing for dynamoDb 2017-02-02 09:20:33 -05:00
stack72 c8a2d40c82
provider/aws: Fixing a merge conflict issue in validators.go 2017-02-02 10:30:41 +00:00
Jack Bruno be56c7d2f6 provider/aws: Add AWS DMS (data migration service) resources (#11122)
* Add aws dms vendoring

* Add aws dms endpoint resource

* Add aws dms replication instance resource

* Add aws dms replication subnet group resource

* Add aws dms replication task resource

* Fix aws dms resource go vet errors

* Review fixes: Add id validators for all resources. Add validator for endpoint engine_name.

* Add aws dms resources to importability list

* Review fixes: Add aws dms iam role dependencies to test cases

* Review fixes: Adjustments for handling input values

* Add aws dms replication subnet group tagging

* Fix aws dms subnet group doesn't use standard error for resource not found

* Missed update of aws dms vendored version

* Add aws dms certificate resource

* Update aws dms resources to force new for immutable attributes

* Fix tests failing on subnet deletion by adding explicit dependencies. Combine import tests with basic tests to cut down runtime.
2017-02-02 10:30:05 +00:00
Raymond Fallon b30ef0f58d Update Application Auto Scaling to support scaling an Amazon EC2 Spot fleet. (#8697)
* provider/aws: Update Application Auto Scaling service model

  - Add support for automatically scaling an Amazon EC2 Spot fleet.

* Remove duplicate policy_type check.

* Test creating a scalable target for a splot fleet request.

* Test creating a scaling policy for a splot fleet request.

* Update resource docs to support scaling an Amazon EC2 Spot fleet.

  - aws_appautoscaling_policy
  - aws_appautoscaling_target

* Remove arn attribute from aws_appautoscaling_target

  - No arn is generated or returned for this resource.

* Remove optional name attribute from aws_appautoscaling_target

  - ScalableTargets do not have a name
  - I think this was copied from aws_appautoscaling_policy

* AWS Application Autoscaling resource documentation tweaks

  - include a target resource in the policy example
  - sort attributes by alpha
  - fixup markdown
  - add spaces to test config
2017-02-02 09:39:22 +00:00
Clint 8f063d6773 Merge pull request #11621 from hashicorp/b-aws-test-fixes
provider/aws: Some Lambda test fixes
2017-02-01 16:39:15 -06:00
clint shryock f87f0f5ba6 provider/aws: Fix permissions for IAM role in Lambda tests 2017-02-01 15:59:40 -06:00
Jake Champlin 3d22adbd5d
provider/aws: Fix root-block-device bug
Previously the `root_block_device` config map was a `schema.TypeSet` with an empty `Set` function, and a hard-limit of 1 on the attribute block.
This prevented a user from making any real changes inside the attribute block, thus leaving the user with a `Apply complete!` message, and nothing changed.

The schema API has since been updated, and we can now specify the `root_block_device` as a `schema.TypeList` with `MaxItems` set to `1`. This fixes the issue, and allows the user to update the `aws_instance`'s `root_block_device` attribute, and see changes actually propagate.
2017-02-01 16:25:07 -05:00
Jake Champlin 91e0fed333
provider/aws: Add tag support to the dynamodb table resource
Adds tag support to the `aws_dynamodb_table` resource. Also adds a test for the resource, and a test to ensure that the tags are populated correctly from a resource import.

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDynamoDBTable_tags'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/01 15:35:00 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSDynamoDBTable_tags -timeout 120m
=== RUN   TestAccAWSDynamoDBTable_tags
--- PASS: TestAccAWSDynamoDBTable_tags (28.69s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    28.713s
```

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDynamoDbTable_importTags'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/01 15:39:49 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSDynamoDbTable_importTags -timeout 120m
=== RUN   TestAccAWSDynamoDbTable_importTags
--- PASS: TestAccAWSDynamoDbTable_importTags (30.62s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    30.645s
```
2017-02-01 15:44:30 -05:00
clint shryock b592f8d35d provider/aws: Fix lambda source mapping tests 2017-02-01 13:25:24 -06:00
Jake Champlin b51edd6175 Merge pull request #11612 from hashicorp/b-fix-beanstalk-env-acctests
provider/aws: Fixes aws beanstalk env acc tests
2017-02-01 13:22:32 -05:00
Paul Stack 851cc46548 provider/aws: Guard against panic in aws_vpc_endpoint_association (#11613)
I believe that if no VPC Endpoints were returned from the AWS API, we
were not guarding against a panic. We were strill trying to inspect the
RouteTableIds. This commit will ensure that no errors are thrown before
trying to use the RouteTableIds

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSVpcEndpointRouteTableAssociation_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/01 18:06:29 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSVpcEndpointRouteTableAssociation_ -timeout 120m
=== RUN   TestAccAWSVpcEndpointRouteTableAssociation_basic
--- PASS: TestAccAWSVpcEndpointRouteTableAssociation_basic (42.83s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	42.859s
```
2017-02-01 18:14:41 +00:00
Jake Champlin f7db75da58
provider/aws: Fixes aws beanstalk env acc tests
Fixes the beanstalk env tests such that they can run in parallel better. Previously, only the beanstalk application was randomized, now the beanstalk environment is also randomized to help better facilitate running our tests in parallel.

```
=== RUN   TestAccAWSBeanstalkEnv_outputs
--- PASS: TestAccAWSBeanstalkEnv_outputs (388.74s)
=== RUN   TestAccAWSBeanstalkEnv_cname_prefix
--- PASS: TestAccAWSBeanstalkEnv_cname_prefix (386.78s)
=== RUN   TestAccAWSBeanstalkEnv_config
--- PASS: TestAccAWSBeanstalkEnv_config (532.56s)
=== RUN   TestAccAWSBeanstalkEnv_resource
--- PASS: TestAccAWSBeanstalkEnv_resource (420.47s)
=== RUN   TestAccAWSBeanstalkEnv_vpc
--- PASS: TestAccAWSBeanstalkEnv_vpc (516.02s)
=== RUN   TestAccAWSBeanstalkEnv_template_change
--- PASS: TestAccAWSBeanstalkEnv_template_change (623.38s)
=== RUN   TestAccAWSBeanstalkEnv_basic_settings_update
--- PASS: TestAccAWSBeanstalkEnv_basic_settings_update (705.32s)
```
2017-02-01 13:09:43 -05:00
Doug Neal babc52202c Succeed creating aws_volume_attachment if identical attachment exists (#11060)
If an `aws_volume_attachment` is identical to one that already exists in
the API, don't attempt to re-create it (which fails), simply act as
though the creation command had already been run and continue.

This allows Terraform to cleanly recover from a situation where a volume
attachment action hangs indefinitely, possibly due to a bad instance
state, requiring manual intervention such as an instance reboot. In such
a situation, Terraform believes the attachment has failed, when in fact
it succeeded after the timeout had expired. On the subsequent retry run,
attempting to re-create the attachment will fail outright, due to the
AttachVolume API call being non-idempotent. This patch implements the
idempotency client-side by matching the (name, vID, iID) tuple.

Note that volume attachments are not assigned an ID by the API.
2017-02-01 15:41:53 +00:00
Jake Champlin c83a971efb Merge pull request #11605 from hashicorp/f-add-docs-ecs-cluster-datasource
documentation: Add documentation for the ECS Cluster Data Source
2017-02-01 10:08:03 -05:00
Jake Champlin ac73ce4199
documentation: Add documentation for the ECS Cluster Data Source
Adds documentation for the ECS Cluster Data Source. Also removes duplicate struct declarations from the data source and test.
2017-02-01 09:51:26 -05:00
Paul Stack ef08adeb65 provider/aws: Fix panic in aws_rds_cluster missing parameter error (#11600)
message

Fixes: #11568

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSRDSCluster_missingUserNameCausesError'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/01 12:11:14 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSRDSCluster_missingUserNameCausesError -timeout 120m
=== RUN   TestAccAWSRDSCluster_missingUserNameCausesError
--- PASS: TestAccAWSRDSCluster_missingUserNameCausesError (3.22s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	3.243s
```

The error message for a required parameter being missing has a wrong parameter baked into it. Therefore, when the error message tried to fire, it was throwing a panic. Added a test to make sure that we know the condition still fires and with a correct message
2017-02-01 14:42:00 +00:00
Jake Champlin 5566edd86e Merge pull request #11558 from hashicorp/feat/data_aws_ecs_cluster2
provider/aws: add aws_ecs_cluster datasource
2017-02-01 09:33:57 -05:00
Paul Stack 50fe7e1bb0 provider/aws: aws_route53_record import error processing (#11603)
Fixes: #11549

When a user passes the wrong argument to a route53_record import, they
got a crash. This was because we expected the ID to parse correctly. The
crash looked like this:

```
% terraform import aws_route53_record.import1 mike.westredd.com
aws_route53_record.import1: Importing from ID "mike.westredd.com"...
aws_route53_record.import1: Import complete!
  Imported aws_route53_record (ID: mike.westredd.com)
aws_route53_record.import1: Refreshing state... (ID: mike.westredd.com)
Error importing: 1 error(s) occurred:

* aws_route53_record.import1: unexpected EOF
panic: runtime error: index out of range
```

Rather than throwing a panic to the user, we should present them with a more useful message that tells them what the error is:

```
% terraform import aws_route53_record.import mike.westredd.com
aws_route53_record.import: Importing from ID "mike.westredd.com"...
aws_route53_record.import: Import complete!
  Imported aws_route53_record (ID: mike.westredd.com)
aws_route53_record.import: Refreshing state... (ID: mike.westredd.com)
Error importing: 1 error(s) occurred:

* aws_route53_record.import: Error Importing aws_route_53 record. Please make sure the record ID is in the form ZONEID_RECORDNAME_TYPE (i.e. Z4KAPRWWNC7JR_dev_A
```

At least they can work out what the problem is in this case
2017-02-01 14:15:08 +00:00
KOJIMA Kazunori 427b0042bb provider/aws: Add sensitive attribute in master_password (#11584) 2017-02-01 11:10:51 +00:00
Raphael Randschau acb55ecc1b provider/aws: code review feedback 2017-02-01 09:32:19 +01:00
Raphael Randschau 1e847c2148
provider/aws: avoid ecs cluster name collisions 2017-01-31 23:40:31 +01:00
Jake Champlin 039701fa51 Merge pull request #11580 from hashicorp/b-fix-panic-data-azs
provider/aws: Fix panic from AZs Data Source Test
2017-01-31 16:06:08 -05:00
Jake Champlin 421b25cacf
provider/aws: Fix panic from AZs Data Source Test
The `aws_availability_zones` data source test was panicking. This fixes both tests

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAvailabilityZones'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/31 15:47:39 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAvailabilityZones -timeout 120m
=== RUN   TestAccAWSAvailabilityZones_basic
--- PASS: TestAccAWSAvailabilityZones_basic (12.56s)
=== RUN   TestAccAWSAvailabilityZones_stateFilter
--- PASS: TestAccAWSAvailabilityZones_stateFilter (13.59s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    26.187s
```
2017-01-31 15:54:17 -05:00
clint shryock 0e5f08e87d change vpc test name to isolate it 2017-01-31 14:50:21 -06:00
Jake Champlin e81231035c Merge pull request #11579 from hashicorp/b-fix-beanstalk-tests
provider/aws: Fix ElasticBeanstalk Acceptance Tests
2017-01-31 15:28:37 -05:00
Gauthier Wallet 4da1451971 Added Step Function resources (State Machine & Activity) (#11420)
* Added Step Function Activity & Step Function State Machine

* Added SFN State Machine documentation

* Added aws_sfn_activity & documentation

* Allowed import of sfn resources

* Added more checks on tests, fixed documentation

* Handled the update case of a SFN function (might be already deleting)

* Removed the State Machine import test file

* Fixed the eventual consistency of the read after delete for SFN functions
2017-01-31 20:17:38 +00:00
Jake Champlin 3541b9254e
provider/aws: Fix ElasticBeanstalk Acceptance Tests
Fixes all the currently failing ElasticBeanstalk Acceptance Tests

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSBeanstalkEnv'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/31 12:47:39 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSBeanstalkEnv -timeout 120m
=== RUN   TestAccAWSBeanstalkEnv_basic
--- PASS: TestAccAWSBeanstalkEnv_basic (383.73s)
=== RUN   TestAccAWSBeanstalkEnv_tier
--- PASS: TestAccAWSBeanstalkEnv_tier (629.41s)
=== RUN   TestAccAWSBeanstalkEnv_outputs
--- PASS: TestAccAWSBeanstalkEnv_outputs (374.11s)
=== RUN   TestAccAWSBeanstalkEnv_cname_prefix
--- PASS: TestAccAWSBeanstalkEnv_cname_prefix (429.19s)
=== RUN   TestAccAWSBeanstalkEnv_config
--- PASS: TestAccAWSBeanstalkEnv_config (512.37s)
=== RUN   TestAccAWSBeanstalkEnv_resource
--- PASS: TestAccAWSBeanstalkEnv_resource (358.39s)
=== RUN   TestAccAWSBeanstalkEnv_vpc
--- PASS: TestAccAWSBeanstalkEnv_vpc (479.72s)
=== RUN   TestAccAWSBeanstalkEnv_template_change
--- PASS: TestAccAWSBeanstalkEnv_template_change (792.78s)
=== RUN   TestAccAWSBeanstalkEnv_basic_settings_update
--- PASS: TestAccAWSBeanstalkEnv_basic_settings_update (616.77s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    4576.505s
```
2017-01-31 15:16:22 -05:00
Clint 3cb8557d54 Merge pull request #11565 from hashicorp/b-aws-ecs-service-type-case
provider/aws: Fix issue with ECS Placement Strat. and type casing
2017-01-31 12:16:17 -06:00
clint shryock 7e9bfda31a provider/aws: Fix issue with ECS Placement Strat. and type casing
The API asks you to send lower case values, but returns uppercase ones.
Here we lowercase the returned API values.

There is no migration here because the field in question is nested in a
set, so the hash will change regardless. Anyone using this feature now
has it broken anyway.
2017-01-31 11:33:16 -06:00
Naoto Yokoyama e2b3ee5fbf provider/aws: add `aws_ecs_task_definition` datasource (#8509) 2017-01-31 17:28:11 +00:00
Jake Champlin ab9c94e331 Merge pull request #11563 from hashicorp/b-fix-instance-data-source-acctests
provider/aws: Fix aws instance data source acceptance tests
2017-01-31 12:25:00 -05:00
Jake Champlin f7d9e0b168
provider/aws: Fix aws instance data source acceptance tests
Fixes 2 acceptance tests for the `aws_instance` data source

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSInstanceDataSource_SecurityGroups'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/31 12:12:15 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSInstanceDataSource_SecurityGroups -timeout 120m
=== RUN   TestAccAWSInstanceDataSource_SecurityGroups
--- PASS: TestAccAWSInstanceDataSource_SecurityGroups (119.14s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    119.172s
```

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSInstanceDataSource_tags'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/31 12:15:42 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSInstanceDataSource_tags -timeout 120m
=== RUN   TestAccAWSInstanceDataSource_tags
--- PASS: TestAccAWSInstanceDataSource_tags (118.87s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    118.900s
```
2017-01-31 12:19:25 -05:00
Jake Champlin 7e23340f3a
provider/aws: Fix Cloudwatch Log acceptance tests
Fixes `aws_cloudwatch_log_group` and `aws_cloudwatch_log_metric_filter` acceptance tests

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSCloudWatchLogMetricFilter_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/31 12:01:05 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSCloudWatchLogMetricFilter_basic -timeout 120m
=== RUN   TestAccAWSCloudWatchLogMetricFilter_basic
--- PASS: TestAccAWSCloudWatchLogMetricFilter_basic (27.36s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    27.390s
```

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSCloudWatchLogGroup_multiple'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/31 12:03:18 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSCloudWatchLogGroup_multiple -timeout 120m
=== RUN   TestAccAWSCloudWatchLogGroup_multiple
--- PASS: TestAccAWSCloudWatchLogGroup_multiple (16.39s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    16.422s
```
2017-01-31 12:06:06 -05:00
Raphael Randschau 12f55f4747 provider/aws: add aws_ecs_cluster datasource
since remove state is deprecated one needs a way to import an ecs_cluster
2017-01-31 17:48:51 +01:00
Linda Xu 2639ffcbec add Aurora create corss region read replica cluster function (#11428) 2017-01-31 13:39:24 +00:00
Jake Champlin 9de405ca31 provider/aws: Fix AWS EIP Assocaition Tests (#11533)
Fixes `aws_eip_association` acceptance tests

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEIPAssociation_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/30 18:31:28 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEIPAssociation_basic -timeout 120m
=== RUN   TestAccAWSEIPAssociation_basic
--- PASS: TestAccAWSEIPAssociation_basic (142.33s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    142.354s
```
2017-01-31 11:04:42 +00:00
Matthew 28cee57ef5 S3 Bucket Object Sever Side Encryption (#11261)
* added server_side_encryption to s3_bucket_object resource including associated acceptance test and documentation.

* got acceptance tests passing.

* made server_side_encryption a computed attribute and only set kms_key_id attribute if an S3 non-default master key is in use.

* ensured kms api is only interrogated if required.
2017-01-31 09:20:48 +00:00
Clint be9fc64967 Merge pull request #11530 from hashicorp/b-aws-test-fixes
provider/aws: Handful of Acc configuration tests
2017-01-30 16:13:24 -06:00
clint shryock 2313281eba fix db option group test 2017-01-30 15:48:52 -06:00
Jake Champlin c0c06ee876 Merge pull request #11526 from hashicorp/b-fix-rds-cluster-param-group-tests
provider/aws: Fix AWS RDS Cluster Parameter Group Tests
2017-01-30 16:36:21 -05:00
Jake Champlin 1b713e87b8
provider/aws: Fix AWS RDS Cluster Parameter Group Tests
Fixes `aws_rds_cluster_parameter_group` acceptance tests, which have been broken since aa8c2ac587

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDBClusterParameterGroupOnly'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/30 16:20:38 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSDBClusterParameterGroupOnly -timeout 120m
=== RUN   TestAccAWSDBClusterParameterGroupOnly
--- PASS: TestAccAWSDBClusterParameterGroupOnly (15.26s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	15.282s
```

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDBClusterParameterGroup_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/30 16:22:48 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSDBClusterParameterGroup_basic -timeout 120m
=== RUN   TestAccAWSDBClusterParameterGroup_basic
--- PASS: TestAccAWSDBClusterParameterGroup_basic (29.48s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	29.510s
```
2017-01-30 16:28:24 -05:00
clint shryock 75121fe00e clean up db subnet name collisiosn 2017-01-30 15:19:24 -06:00
clint shryock 7fcbc0495c randomize Beanstalk test name 2017-01-30 15:06:29 -06:00
Jake Champlin c9dd87d03a
provider/aws: Fix cloudwatch log subscription filter test
Fixes `aws_cloudwatch_log_subscription_filter` acceptance tests that had been failing since mid December

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSCloudwatchLogSubscriptionFilter_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/30 16:00:05 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSCloudwatchLogSubscriptionFilter_basic -timeout 120m
=== RUN   TestAccAWSCloudwatchLogSubscriptionFilter_basic
--- PASS: TestAccAWSCloudwatchLogSubscriptionFilter_basic (26.34s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	26.364s
```
2017-01-30 16:03:55 -05:00
Jake Champlin feafe3c0b5
provider/aws: Fix acceptance tests for autoscaling schedule
Fixes acceptance tests for `aws_autoscaling_schedule` resource

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAutoscalingSchedule_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/30 14:40:34 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAutoscalingSchedule_basic -timeout 120m
=== RUN   TestAccAWSAutoscalingSchedule_basic
--- PASS: TestAccAWSAutoscalingSchedule_basic (170.38s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	170.406s
```

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAutoscalingSchedule_disappears'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/30 15:00:49 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAutoscalingSchedule_disappears -timeout 120m
=== RUN   TestAccAWSAutoscalingSchedule_disappears
--- PASS: TestAccAWSAutoscalingSchedule_disappears (179.23s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	179.253s
```
2017-01-30 15:07:10 -05:00
Jake Champlin 9cdd7547e1 Merge pull request #11474 from hashicorp/b-fix-aws-alb-import
provider/aws: Import aws_alb_listener_rule fix
2017-01-30 08:49:24 -05:00
yn 8ea5d53954 SNS Topic Subscription: import more attributes (#10408) 2017-01-30 11:52:23 +00:00
snakeb1t 747ca75bfe kms CreateKey: retry if arn in policy not yet seen (#11509)
if KMS service doesn't think a resource exists which is listed in
a Key policy, then CreateKey fails. so retry until it's seen
by KMS service.
2017-01-30 11:23:43 +00:00
Brad Sickles ea642dd1ee Initial commit from @BSick7:
Implementing vpc_peering_connection_accept.

Additions from @ewbankkit:
Rename 'aws_vpc_peering_connection_accept' to 'aws_vpc_peering_connection_accepter'.
Get it working reusing functionality from 'aws_vpc_peering_connection' resource.
2017-01-29 18:53:01 -05:00
Borgstrom ♕ 01a6bd7592 provider/aws: New data provider to decrypt KMS secrets (#11460)
* Add a new data provider to decrypt AWS KMS secrets

* Address feedback

* Rename aws_kms_secrets to aws_kms_secret
* Add more examples to the documentation
2017-01-29 21:01:38 +00:00
Paul Stack 4ebd207803 provider/aws: Add support for policy to AWS provider assume_role (#11501)
Fixes: #11461

This will allow the user to pass a policy to further restrict the use
of AssumeRole. It is important to note that it will NOT allow an
expansion of access rights
2017-01-29 20:32:24 +00:00
julius-bonial 5d8662d5da fix wrong usage of hashicorp/errwrap (#11500)
According to https://github.com/hashicorp/errwrap
'{{err}}' has to be used instead of '%s'

Without this patch, error output from terraform is missing important information:
* aws_cloudwatch_log_group.logs: Error Getting CloudWatch Logs Tag List: %s

With this patch, I get the important information. E.g.:
* aws_cloudwatch_log_group.logs: Error Getting CloudWatch Logs Tag List: AccessDeniedException: User: arn:aws:sts::XYZ:assumed-role/AAA-BBB-CCC/terraform-assuming-role-assume-role-ReadOnly is not authorized to perform: logs:ListTagsLogGroup on resource: arn:aws:logs:us-east-1:XYZ:log-group:logs:log-stream:
2017-01-29 19:19:48 +00:00
Jake Champlin 96f6044908 provider/aws: ECS Placement constraints fix (#11475)
* fixing AWS ECS placement constraints

* correcting AWS ECS task definition doc

* reverting unnecessary change to resource_aws_ecs_task_definition

* provider/aws: ECS Placement constraints fix

Expands upon #11446 from @bgetsug

Adds:
 - Acceptance Test
 - Improves `nil` check on constraint expression

 Fixes: #10968
2017-01-29 16:42:50 +00:00
Jake Champlin 8b66d137d1
provider/aws: Import aws_alb_listener_rule fix
Allows the user to import a default aws_alb_listener_rule. When creating the resource with TF, the AWS API requires that `priority` be an integer.
However, the `DescribeRules` API call returns a string for `priority`. This would work in every case except for the `default` listener rule, which sets the `priority` value to the string "default".

This fixes the previous error:
```
Error importing: 1 error(s) occurred:

* aws_alb_listener_rule.test: Cannot convert rule priority %q to int: strconv.ParseInt: parsing "default": invalid syntax
```

Fixes: #11464
2017-01-27 14:55:34 -05:00
Jack Pearkes b0096abbe3 provider/aws: allow destroy of LB stickiness policy with missing LB (#11462)
Previously an attempt to destroy a LB stickiness policy would
result in an error like this:

```
* aws_lb_cookie_stickiness_policy.foo: Error removing LBCookieStickinessPolicy: LoadBalancerNotFound: There is no ACTIVE Load Balancer named 'tf-test-lb-tqatd'
    status code: 400, request id: 28af1167-e4a4-11e6-8ddd-57ba410cbbb6
```

This checks for a missing load balancer on the policy read and allows
the destroy.

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSLBCookieStickinessPolicy_missingLB'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/27 07:21:11 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSLBCookieStickinessPolicy_missingLB -timeout 120m
=== RUN   TestAccAWSLBCookieStickinessPolicy_missingLB
--- PASS: TestAccAWSLBCookieStickinessPolicy_missingLB (28.90s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    28.929s
```
2017-01-27 21:14:23 +02:00
Jake Champlin 0cd69d2101 Merge pull request #11411 from hashicorp/f-emr-instance-ebs-volumes
provider/aws: Add EBS Volume support for EMR Instance Groups
2017-01-27 09:57:28 -05:00
Clint e3c89da542 Merge pull request #11383 from brad-larson/brad-fix-regexp-validation
Fix: Incorrect AWS Lambda Qualifier Regexp
2017-01-26 16:38:00 -06:00
Tero Keinänen eb70c538a8 Fix: path not updated when modifying AWS API Gateway Resource
Fixes #11442
2017-01-26 21:53:08 +02:00
Clint c453c6d189 Merge pull request #10953 from Biteable/spot-fleet-terminate
only wait for spot fleet instance termination if requested
2017-01-25 15:11:48 -06:00
Jake Champlin 1c805c49b0 provider/aws: Fix RouteTable data source test (#11410)
Fixes the `TestAccDataSourceAwsRouteTable_main` acceptance test.

```
=== RUN   TestAccDataSourceAwsRouteTable_main
--- PASS: TestAccDataSourceAwsRouteTable_main (11.19s)
```
2017-01-25 19:50:37 +02:00
Jake Champlin a60f35e694
provider/aws: Add EBS Volume support for EMR Instance Groups
Adds EBS Volume support and tests for EMR Instnace Groups

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEMRInstanceGroup_ebsBasic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/25 10:14:58 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEMRInstanceGroup_ebsBasic -timeout 120m
=== RUN   TestAccAWSEMRInstanceGroup_ebsBasic
--- PASS: TestAccAWSEMRInstanceGroup_ebsBasic (675.14s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    675.171s
```
2017-01-25 10:29:41 -05:00
Jake Champlin dc91285949 Merge pull request #11369 from hashicorp/f-add-suppress-func-db-instance
provider/aws: Add diff suppress function for aws_db_instance
2017-01-24 12:30:25 -05:00
Brad Larson c5c2d27e25 Fix: Incorrect AWS Lambda Qualifier Regexp
Type of change:
===============
- Bug fix

What changed? ... and Why:
==========================
The regexp is currently set to:
`pattern := `^[a-zA-Z0-9$_]+$`

The AWS docs state that qualifer names must conform to the following
regexp:
`Pattern: (|[a-zA-Z0-9$_-]+)`

As you can see, the current regexp in Terraform is missing the `-` at
the end.

This addresses that.

How has it been tested?
=======================
Added a few test cases to the existing spec for `AwsLambdaQualifier`
validation.
2017-01-24 15:57:57 +00:00
Gauthier Wallet 92d723609e provider/aws: Added a S3 Bucket domain name attribute (#10088) 2017-01-24 15:54:46 +02:00
Radek Simko cbaf051af5 provider/aws: Fix acceptance tests w/ missing values (#11377) 2017-01-24 14:09:29 +02:00
Radek Simko e81d096699 provider/aws: Fix failing ecs acceptance test w/ ALB (#11367) 2017-01-24 01:58:30 +02:00
Jake Champlin 4c5a08cae7
fix fat-fingered change in test 2017-01-23 18:28:16 -05:00
Jake Champlin 4e7ccc35a3
provider/aws: Add diff suppress function for aws_db_instance
Adds a diff suppress function for the `engine_version` attribute of the `db_instance` AWS resource.

The function only supresses the state diff, if the attribute key `auto_minor_version_upgrade` is set, and if the returned `engine_version` from the running RDS instance shares the same prefix as the configured `engine_version`.

 ```
 $ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDBInstance_MinorVersion'
 ==> Checking that code complies with gofmt requirements...
 go generate $(go list ./... | grep -v /terraform/vendor/)
 2017/01/23 17:59:14 Generated command/internal_plugin_list.go
 TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSDBInstance_MinorVersion -timeout 120m
 === RUN   TestAccAWSDBInstance_MinorVersion
 --- PASS: TestAccAWSDBInstance_MinorVersion (503.48s)
 PASS
 ok      github.com/hashicorp/terraform/builtin/providers/aws    503.518s
 ```
2017-01-23 18:12:34 -05:00
Kit Ewbank 87d98b1ff1 Correct aws_s3_bucket_object data source acceptance tests. (#11346) 2017-01-23 21:53:02 +00:00
Kit Ewbank c5f94d2999 Add 'aws_vpc_endpoint' data source. (#11323) 2017-01-23 21:50:38 +00:00
Kit Ewbank cbe4a99d31 Add 'aws_canonical_user_id' data source. (#11332) 2017-01-23 21:44:42 +00:00
Radek Simko 6791735790 Merge pull request #11358 from radeksimko/f-aws-skip-region-validation
provider/aws: Allow bypassing region validation
2017-01-23 21:31:52 +00:00
James Nugent 19e55457c9 Merge pull request #11360 from hashicorp/asg-hook-errors
provider/aws: Improve error message from ASG Hooks
2017-01-23 17:47:07 +00:00
James Nugent b95faa3f12 provider/aws: Improve error message from ASG Hooks
This commit switches out the use of `fmt.Errorf` to `errwrap.Wrapf` in
the `aws_autoscaling_lifecycle_hook` resource, and corrects a typo which
causes the parameter object to be returned to a user rather than the
underlying error.
2017-01-23 17:35:47 +00:00
Jake Champlin 8580f58063
Use strings.HasPrefix instead of regexp for lambda_permission 2017-01-23 12:34:56 -05:00
Jake Champlin 763cfcdb1f
Use strings.HasPrefix instead of regexp for ecs_service 2017-01-23 12:02:53 -05:00
Jake Champlin 8159731c91
provider/aws: Allow ARN identifier to be set
Allows users from govcloud and other regions (aws-cn) to now use the following resources correctly:

```
- data "aws_billing_service_account"
- data "aws_elb_service_account"
- resource "aws_cloudfront_origin_access_identity"
- resource "aws_ecs_service"
- resource "aws_iam_saml_provider"
- resource "aws_lambda_permission"
- resource "aws_sns_topic_policy"
```
2017-01-23 11:30:28 -05:00
Radek Simko 6d8d596883
provider/aws: Allow bypassing region validation 2017-01-23 15:04:46 +00:00
Jake Champlin c5126b5add Merge pull request #11340 from svanzoest/patch-1
provider/aws: Remove MaxFrameRate default on Elastictranscoder Preset
2017-01-23 09:21:20 -05:00
Jake Champlin 2efe489d59 Merge pull request #11339 from jmcarp/issue-10061
Set correct aws partition on s3 resource.
2017-01-23 09:17:33 -05:00
James Nugent 6013dc06a9 Merge pull request #11333 from radeksimko/f-aws-alb-wait
provider/aws: Wait until ALB is actually provisioned
2017-01-23 01:48:09 +00:00
Jake Champlin aa3eda7642 Merge pull request #11313 from hashicorp/f-fix-s3bucketpolicy-acctests
provider/aws: Fix S3BucketPolicy Acceptance Tests
2017-01-22 15:41:21 -05:00
Sander van Zoest ec9aff034f aws/elastic_transcoder remove default MaxFrameRate
Fixes #9847
2017-01-22 12:39:23 -08:00
Joshua Carp 353430e08a
Set correct aws partition on s3 resource.
[Resolves #10061]
2017-01-22 15:05:35 -05:00
Radek Simko 41da963d07
provider/aws: Make ALBs internal or add IGW in tests 2017-01-21 22:00:36 +00:00
Jake Champlin b9ade93a48 Merge pull request #11298 from hashicorp/f-update-ecs-definitions-constraints
provider/aws: Update ECS task_definition and service
2017-01-20 17:34:10 -05:00
Clint 7c5b3a5012 Merge pull request #11291 from hashicorp/pr-10985
provider/aws: implement CloudFront Lambda Function Associations (supersedes #10985)
2017-01-20 16:34:03 -06:00
clint shryock fd3f4bbf3d fix up a test to actually compare them 2017-01-20 16:20:32 -06:00
Paul Stack 3b2c4ee2ed provider/aws: Remove hardcoded https from the ecr repository (#11307)
* provider/aws: Remove hardcoded https from the ecr repository

When the ECR resource was created, we hardcoded the repository URL to
start with https://

This was a mistake as all interaction with the repository now must
include a replace function for the https:// to "" for this to be usable

We need to note this change in the backward incompatibilities

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEcrRepository_'                                                      ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/20 14:37:36 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEcrRepository_ -timeout 120m
=== RUN   TestAccAWSEcrRepository_importBasic
--- PASS: TestAccAWSEcrRepository_importBasic (20.46s)
=== RUN   TestAccAWSEcrRepository_basic
--- PASS: TestAccAWSEcrRepository_basic (18.77s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	39.251s
```

* Update ecr_repository.html.markdown
2017-01-20 17:34:52 +00:00
clint shryock 91753409b9 fix issue where, depending on a creation of flattening, the lambda functions may be a set or an []interface{} 2017-01-20 11:25:30 -06:00
Jake Champlin 191bb15830
provider/aws: Fix S3BucketPolicy Acceptance Tests
Fixes AwsS3BucketPolicy Acceptance Tests to match policy document changes from upstream.

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSS3BucketPolicy'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/20 11:55:23 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSS3BucketPolicy -timeout 120m
=== RUN   TestAccAWSS3BucketPolicy_basic
--- PASS: TestAccAWSS3BucketPolicy_basic (33.64s)
=== RUN   TestAccAWSS3BucketPolicy_policyUpdate
--- PASS: TestAccAWSS3BucketPolicy_policyUpdate (61.91s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    95.591s
```
2017-01-20 11:58:15 -05:00
Radek Simko acd2b247b4
provider/aws: Wait until ALB is provisioned 2017-01-20 06:50:50 -08:00
Dylan Vaughn 2aca4a4d99 provider/aws: CloudFormation YAML template support (#11121) 2017-01-20 14:00:32 +00:00
Paul Stack f8a3564065 provider/aws: Add DataSource to get a list of Autoscaling groups in a (#11303)
region
2017-01-20 13:21:12 +00:00
Jake Champlin 5276496e6d
provider/aws: Update ECS task_definition and service
Updates ECS task_definition documentation, and schema validation functions to match the AWS API documentation.

Updates ECS service documentation, and schema validation functions match the AWS API documentation.
2017-01-19 17:54:52 -05:00
clint shryock 6d4f4007fe restore lambdasethash, include in cache behavior id hash, and document (including limits) 2017-01-19 15:53:52 -06:00
clint shryock 5400f7c68e fix hash problem 2017-01-19 09:28:49 -06:00
clint shryock 2cf64ef72c tweaks to restore TypeSet functionality 2017-01-19 09:22:02 -06:00
Jake Champlin de80ebd073 Merge pull request #11272 from hashicorp/f-add-instance-datasource
provider/aws: Add aws_instance data source
2017-01-18 18:30:49 -05:00
Jake Champlin c99bc8a807
Add instance_tags as an additional filter 2017-01-18 13:14:49 -05:00
Jake Champlin 9cbd67dd0b
provider/aws: Add aws_instance data source
Adds the `aws_instance` data source, tests, and documentation.

```
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/18 11:49:09 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSInstanceDataSource -timeout 120m
=== RUN   TestAccAWSInstanceDataSource_basic
--- PASS: TestAccAWSInstanceDataSource_basic (106.24s)
=== RUN   TestAccAWSInstanceDataSource_AzUserData
--- PASS: TestAccAWSInstanceDataSource_AzUserData (108.52s)
=== RUN   TestAccAWSInstanceDataSource_gp2IopsDevice
--- PASS: TestAccAWSInstanceDataSource_gp2IopsDevice (80.71s)
=== RUN   TestAccAWSInstanceDataSource_blockDevices
--- PASS: TestAccAWSInstanceDataSource_blockDevices (94.07s)
=== RUN   TestAccAWSInstanceDataSource_rootInstanceStore
--- PASS: TestAccAWSInstanceDataSource_rootInstanceStore (95.17s)
=== RUN   TestAccAWSInstanceDataSource_privateIP
--- PASS: TestAccAWSInstanceDataSource_privateIP (241.75s)
=== RUN   TestAccAWSInstanceDataSource_keyPair
--- PASS: TestAccAWSInstanceDataSource_keyPair (208.77s)
=== RUN   TestAccAWSInstanceDataSource_VPC
--- PASS: TestAccAWSInstanceDataSource_VPC (109.89s)
=== RUN   TestAccAWSInstanceDataSource_SecurityGroups
--- PASS: TestAccAWSInstanceDataSource_SecurityGroups (118.66s)
=== RUN   TestAccAWSInstanceDataSource_VPCSecurityGroups
--- PASS: TestAccAWSInstanceDataSource_VPCSecurityGroups (136.79s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    1300.625s
```
2017-01-18 12:19:44 -05:00
Clint c5f899d64c Merge pull request #11247 from hashicorp/b-aws-rds-mssql-timezone
provider/aws: Add support for setting MSSQL Timezone in aws_db_instance
2017-01-18 08:39:41 -06:00
clint shryock 549fd22c87 provider/aws: Add support for setting MSSQL Timezone in aws_db_instance 2017-01-18 08:39:18 -06:00
Eric Lee 33f781be36 provider/aws allow ALB target group stickiness to be enabled (#11251)
* aws_alb_target_group allow stickiness to be disabled

* aws_alb_target_group document stickiness enabled flag
2017-01-18 14:10:09 +00:00
Paul Stack 36b6384956 provider/aws: Add support for placement_constraint to aws_ecs_service (#11242)
```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEcsServiceWithPlacementConstraints'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/17 18:25:27 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEcsServiceWithPlacementConstraints -timeout 120m
=== RUN   TestAccAWSEcsServiceWithPlacementConstraints
--- PASS: TestAccAWSEcsServiceWithPlacementConstraints (113.18s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	113.208s
```

//cc @catsby
2017-01-17 18:43:34 +00:00
Greg Thole e06f32ffe9 Provider AWS: Add Placement Strategy to aws_ecs_service resource (#11201)
* Add aws_ecs_service placement_strategy param

* Update docs
2017-01-17 18:10:44 +00:00
David Blooman 05c83a3ca1 provider/aws: Add Inspector Support (#11217)
* provider/aws: Add Inspector Support

* inscrease time to 1 hour
2017-01-17 17:30:46 +00:00
James Bardin ee1d6d3d43 Fix vet errors in providers 2017-01-13 17:31:44 -05:00
Clint 2599137150 Merge pull request #11164 from johanneswuerbach/aws-route53-changeable-record-type
provider/aws: Make the type of a route53_record changeable
2017-01-13 13:51:35 -06:00
Paul Stack 8e4f19918a provider/aws: Add Support for aws_cloudwatch_metric_alarm extended (#11193)
statistic

Fixes: #11189

This introduces a new parameter and makes an existing parameter from
`required` to `optional` as both cannot be specified together

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSCloudWatchMetricAlarm_' 2 ↵ ✹ ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/13 11:25:24 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSCloudWatchMetricAlarm_ -timeout 120m
=== RUN   TestAccAWSCloudWatchMetricAlarm_importBasic
--- PASS: TestAccAWSCloudWatchMetricAlarm_importBasic (19.80s)
=== RUN   TestAccAWSCloudWatchMetricAlarm_basic
--- PASS: TestAccAWSCloudWatchMetricAlarm_basic (20.42s)
=== RUN   TestAccAWSCloudWatchMetricAlarm_extendedStatistic
--- PASS: TestAccAWSCloudWatchMetricAlarm_extendedStatistic (18.92s)
PASS
```
2017-01-13 14:47:58 +00:00
Jake Champlin a2c0b85b2d Merge pull request #11162 from hashicorp/f-add-route53-record-import-10941
provider/aws: Add import to route53 record
2017-01-12 12:08:46 -05:00
Jake Champlin bb0b9048b0 Merge pull request #11178 from hashicorp/cloudwatch-log-tags
provider/aws: Add Support for Tags to aws_cloudwatch_log_group
2017-01-12 10:21:07 -05:00
Paul Stack 6b292c23dc Update resource_aws_cloudwatch_log_group.go 2017-01-12 17:14:29 +02:00
Paul Stack bcdabe7619 provider/aws: New DataSource: aws_elb_hosted_zone_id (#11027)
* provider/aws: New DataSource: aws_elb_hosted_zone_id

This datasource is a list of all of the ELB DualStack Hosted Zone IDs.
This will allow us to reference the correct hosted zone id when creating
route53 alias records

There are many bugs for this - this is just the beginning of fixing them

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSElbHostedZoneId_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/04 13:04:32 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSElbHostedZoneId_basic -timeout 120m
=== RUN   TestAccAWSElbHostedZoneId_basic
--- PASS: TestAccAWSElbHostedZoneId_basic (20.46s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	20.484s
```

* Update elb_hosted_zone_id.html.markdown
2017-01-12 16:50:58 +02:00
stack72 188350458c
provider/aws: Add Support for Tags to aws_cloudwatch_log_group
``````
make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSCloudWatchLogGroup_'                               2 ↵ ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/12 16:22:07 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSCloudWatchLogGroup_ -timeout 120m
=== RUN   TestAccAWSCloudWatchLogGroup_importBasic
--- PASS: TestAccAWSCloudWatchLogGroup_importBasic (44.20s)
=== RUN   TestAccAWSCloudWatchLogGroup_basic
--- PASS: TestAccAWSCloudWatchLogGroup_basic (38.08s)
=== RUN   TestAccAWSCloudWatchLogGroup_retentionPolicy
--- PASS: TestAccAWSCloudWatchLogGroup_retentionPolicy (55.85s)
=== RUN   TestAccAWSCloudWatchLogGroup_multiple
--- PASS: TestAccAWSCloudWatchLogGroup_multiple (20.68s)
=== RUN   TestAccAWSCloudWatchLogGroup_disappears
--- PASS: TestAccAWSCloudWatchLogGroup_disappears (21.48s)
=== RUN   TestAccAWSCloudWatchLogGroup_tagging
--- PASS: TestAccAWSCloudWatchLogGroup_tagging (39.09s)
ok
PASS	github.com/hashicorp/terraform/builtin/providers/aws	219.411s
```
2017-01-12 16:39:12 +02:00
Paul Stack 73e950989c provider/aws: Allow creating aws_codecommit repository outside of (#11177)
us-east-1

Fixes #11175

Because of a previous limitation that codecommit only ran in us-east-1,
we hard coded the session under which it should run. This has caused the
repository to be spun up in the wrong region regardless of what region
was passed to the provider

```
make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSCodeCommitRepository_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/12 16:09:52 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSCodeCommitRepository_ -timeout 120m
=== RUN   TestAccAWSCodeCommitRepository_basic
--- PASS: TestAccAWSCodeCommitRepository_basic (23.28s)
=== RUN   TestAccAWSCodeCommitRepository_withChanges
--- PASS: TestAccAWSCodeCommitRepository_withChanges (33.71s)
=== RUN   TestAccAWSCodeCommitRepository_create_default_branch
--- PASS: TestAccAWSCodeCommitRepository_create_default_branch (22.70s)
=== RUN   TestAccAWSCodeCommitRepository_create_and_update_default_branch
--- PASS: TestAccAWSCodeCommitRepository_create_and_update_default_branch (32.72s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	112.437s
```
2017-01-12 16:27:04 +02:00
Johannes Würbach ef0196f754
provider/aws: Make the type of a route53_record changeable
Utilize the ChangeResourceRecordSets to change the type of a record by
deleting and recreating with a new type.

As change batches are considered transactional changes, Amazon Route 53
either makes all or none of the changes in the batch request ensuring the
update will never be partially applied.
2017-01-12 13:13:35 +01:00
Jake Champlin e579c1c90f
provider/aws: Add import to route53 record
Allows the user to run:

```
terraform import aws_route53_record.record_name <record_id>
```

Fixes: #10941
2017-01-11 17:38:02 -05:00
Jake Champlin 642e0107e1
Update error message to 'route_table_id' 2017-01-11 13:23:40 -05:00
Jake Champlin 439b94707e
Use 'route_table_id' instead of 'rtb_id' 2017-01-11 13:22:29 -05:00
Jake Champlin d794bdfc26
provider/aws: Add missing id argument for Route Table data source
Documentation for the `aws_route_table` data source mentions that it supports a route table `id` as an argument, however it was missing from the actual provider code.

Adds in the missing provider code, adds a test, and updates the documentation to use `rtb_id` as the argument, instead of the more ambiguous `id`.
2017-01-11 13:16:52 -05:00
Jake Champlin 7399401b64
provider/aws: Fix panic caused by main route table lookup
A VPC's main route table has an implicit subnet association, not an explicit subnet association. This caused a Terraform panic when using the `data_source_aws_route_table` resource to query the main route table for a VPC.

This fixes the Terraform panic, and allows the data lookup to complete successfully. Also added an acceptance test to verify the bugfix.

Fixes: #11134
2017-01-11 12:33:15 -05:00
Ninir fe60b4e90a Added aws-sdk-go SFN service (#11109) 2017-01-10 14:17:39 +00:00
Clint c0d0f711d9 provider/aws: Allow disabled access_log in ELB (#11120)
* provider/aws: Save disabled ELB accesslogs to state

Save any explicitly disabled access_log to state. Do not save disabled
access_logs if they are not in the configuration.

* test that fails on master
2017-01-09 23:10:58 +00:00
Jake Champlin 1955ac38bc
provider/aws: Route53 Record: Add Type validation
Adds validation for the `type` parameter of an `aws_route53_record` resource.

This will allow Terraform to catch any user errors of a `type` parameter during a `terraform plan` instead of during a `terraform apply`.

Fixes: #11114
2017-01-09 15:45:26 -05:00
Paul Stack 519d873263 provider/aws: New Resource aws_codedeploy_deployment_config (#11062)
* provider/aws: New Resource - aws_codedeploy_deployment_config

* provider/aws: Adding acceptance tests for new
aws_codedeploy_deployment_config resource

* provider/aws: Documentation for the aws_codedeploy_deployment_config resource

* Update codedeploy_deployment_config.html.markdown
2017-01-09 19:17:09 +00:00
Paul Stack 5ece0f2d04 provider/aws: aws_db_instance restored from snapshot had problem with (#11050)
subnet_group

Fixes #11024

A change was introduced in 0.8.2 that allows db_instances to change
their db_subnet_group. Unfortunately, this caused an issue for
db_instances that were being restored from snapshot. The restore from
snapshot part of create calls the Update func whereas a normal create
calls the Read func

When calling the Update func, the db_instance was trying to go through a
db_subnet_group_name change and was failing for the following reason:

```
InvalidVPCNetworkStateFault: You cannot move DB instance _rds_instance_name_ to subnet group _subnet_group_name_. The specified DB subnet group and DB instance are in the same VPC. Choose a DB subnet group in different VPC than the specified DB instance and try again.
```
2017-01-09 19:10:13 +00:00
Jake Champlin b9d4a54341
provider/aws: Add S3 Bucket name validation
Adds region specific S3 bucket name validation. Currently all regions except for us-east-1 force a dns-compliant naming convention. Thus we cannot utilize the standard `SchemaValidateFunc` interface to validate an S3 bucket name.
 This change creates a helper function outside of the schema validation interface so we can validate S3 bucket names for both naming conventions. At a later date, when the us-east-1 region is updated to conform to a dns-compliant naming scheme, we can refactor the `validateS3BucketName` function to fit the `SchemaValidateFunc` interface.
2017-01-09 11:22:47 -05:00
Paul Stack ba41375fd9 provider/aws: Add support for content_handling to (#11002)
aws_api_gateway_integration_response

This continues the work carried out in #10696

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAPIGatewayIntegrationResponse_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/03 14:18:46 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSAPIGatewayIntegrationResponse_ -timeout 120m
=== RUN   TestAccAWSAPIGatewayIntegrationResponse_basic
--- PASS: TestAccAWSAPIGatewayIntegrationResponse_basic (57.33s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws57.352s
```
2017-01-09 14:46:21 +00:00
Kazuma Watanabe c560c72e58 provider/aws: Validate window time format (#11089)
* create window format validate function

* apply ValidateFunc for window time format
2017-01-09 13:12:07 +00:00
Paul Stack cf390e86b8 provider/aws: Fix up AWS Lambda* tests (#11104)
The tests are complaining of:

```
Errors: []string{"aws_lambda_function.test_lambda: \"runtime\": required field is not set"}
```
2017-01-09 09:56:37 +01:00
Tim Gossett 25f9aeb30a
lambda_function_association as List not Set 2017-01-06 10:59:03 -05:00
Tim Gossett 32f7a86e10
lambda_function_association attribute as []interface{} 2017-01-06 10:20:35 -05:00
clint shryock e4b9e63e90 provider/aws: Update regex to pass test 2017-01-05 15:06:54 -06:00
clint shryock 520029032d provider/aws: fix iam login user test 2017-01-05 14:54:03 -06:00
Tim Gossett 9c5a25dd48
update lambda function association test for new hash order 2017-01-05 13:06:30 -05:00
Tim Gossett fa7eecf508
add lambda_arn to lambda func association hash 2017-01-05 13:05:53 -05:00
clint shryock f4c5b9fada provider/aws: Update lambda_function with runtime for tests 2017-01-05 11:24:17 -06:00
Paul Stack 8542715151 provider/aws: Updating the aws_efs_mount_target dns_name (#11023)
Fixes:#10902

AWS introduced a change to the Mount Target DNS Name to remove the
availability_zone from it -
https://aws.amazon.com/about-aws/whats-new/2016/12/simplified-mounting-of-amazon-efs-file-systems/

This was because there used to be a limit of 1 mount target per AZ -
this has been raised.

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEFSMountTarget_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/04 10:45:35 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEFSMountTarget_ -timeout 120m
=== RUN   TestAccAWSEFSMountTarget_importBasic
--- PASS: TestAccAWSEFSMountTarget_importBasic (236.19s)
=== RUN   TestAccAWSEFSMountTarget_basic
--- PASS: TestAccAWSEFSMountTarget_basic (445.52s)
=== RUN   TestAccAWSEFSMountTarget_disappears
--- PASS: TestAccAWSEFSMountTarget_disappears (228.31s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	910.044s
```
2017-01-04 23:12:45 +00:00
Clint 3b4866042b Merge pull request #10987 from zendesk/fix_10983
aws_key_pair: Ensure key_name attribute is set
2017-01-04 16:18:31 -06:00
Clint cfb597d42d Merge pull request #11043 from hashicorp/b-aws-test-fixes
provider/aws: Fix some failing AWS acc tests
2017-01-04 16:03:47 -06:00
clint shryock b656579211 provider/aws: Randomize lb and policy name in LB policy test 2017-01-04 16:02:02 -06:00
Christian Hildebrando Hercules 63eb0ba870 Increasing timeout for redshift cluster creation
This is in response to creating 25 node cluster, and taking longer than 40 min max.
2017-01-04 13:03:57 -08:00
clint shryock db1c1bec72 add missing runtime param to test 2017-01-04 14:58:47 -06:00
Clint 21e706cb82 Merge pull request #11030 from hashicorp/f-aws-ecs-placement
provider/aws: Add Placement Constraints to ECS Task Definition
2017-01-04 13:41:41 -06:00
Paul Stack 2331a64fd8 provider/aws: aws_kinesis_firehose_delivery_stream code cleanup (#11021)
We `removed` these items in 0.7 and they can be deleted from 0.8 IMO

//cc @catsby
2017-01-04 15:40:41 +00:00
clint shryock a73f947b8d provider/aws: Add Placement Constraints to ECS Task Definition
Adds support for applying placement constraints to
aws_ecs_task_definition resource
2017-01-04 09:10:18 -06:00
Daniel del Castillo cbcb313c08 aws_redshift_cluster: Fix typo security groups update (#11025) 2017-01-04 11:19:49 +00:00
Paul Stack 56c352a535 provider/aws: data_source_aws_iam_server_certificate latest should be (#11016)
bool not string

Fixes: #11010

Adds a test to show cover the use-case that the OP suggested caused the
panic

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDataSourceIAMServerCertificate_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/03 22:39:21 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSDataSourceIAMServerCertificate_ -timeout 120m
=== RUN   TestAccAWSDataSourceIAMServerCertificate_basic
--- PASS: TestAccAWSDataSourceIAMServerCertificate_basic (19.48s)
=== RUN   TestAccAWSDataSourceIAMServerCertificate_matchNamePrefix
--- PASS: TestAccAWSDataSourceIAMServerCertificate_matchNamePrefix (1.95s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	21.454s
```
2017-01-03 22:45:39 +00:00
Paul Stack 8ff44d0056 provider:aws: Add support for updating aws_emr_cluster parameters (#11008)
* provider:aws: Add support for updating aws_emr_cluster parameters

Fixes #10962

We now support the update of `visibile_to_add_users` and
`termination_protected` parameters

```
make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEMRCluster_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/03 18:45:20 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEMRCluster_ -timeout 120m
=== RUN   TestAccAWSEMRCluster_basic
--- PASS: TestAccAWSEMRCluster_basic (551.98s)
=== RUN   TestAccAWSEMRCluster_terminationProtected
--- PASS: TestAccAWSEMRCluster_terminationProtected (545.52s)
=== RUN   TestAccAWSEMRCluster_visibleToAllUsers
--- PASS: TestAccAWSEMRCluster_visibleToAllUsers (552.09s)
=== RUN   TestAccAWSEMRCluster_tags
--- PASS: TestAccAWSEMRCluster_tags (598.91s)
PASS
ok	github.com/hashicorp/terraform/builtin/providers/aws	2248.537s
```

* Update resource_aws_emr_cluster_test.go
2017-01-03 22:15:44 +00:00
Paul Stack cb64fdeb28 provider/aws: Add support for updating tags in aws_emr_cluster (#11003)
Fixes: #10958

This wasn't implemented the first time around for some reason

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEMRCluster_'                                       2 ↵ ✹ ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/03 15:40:09 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEMRCluster_ -timeout 120m
=== RUN   TestAccAWSEMRCluster_basic
--- PASS: TestAccAWSEMRCluster_basic (529.36s)
=== RUN   TestAccAWSEMRCluster_tags
--- PASS: TestAccAWSEMRCluster_tags (556.81s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	1086.197s
```
2017-01-03 18:30:40 +00:00
Tim Gossett c2c7f23bba
fix expectation messages that did not align with code 2017-01-02 23:00:12 -05:00
Paul Stack cb1acca2be provider/aws: Add snapshotting to the list of pending state for (#10965)
elasticache

Fixes #10964
2017-01-02 20:37:43 +00:00
Paul Stack d9088d8cc0 provider/aws: Bump SDK version to 1.6.9 (#10993)
There is 1 breaking change. The OpsWorks Update API no longer supports
`tenancy` as an update. So that has to be marked as ForceNew: true

```
% make testacc TEST=./builtin/providers/aws
% TESTARGS='-run=TestAccAWSOpsworksInstance'
% 2 ↵ ✹ ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/01/02 17:11:29 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSOpsworksInstance -timeout 120m
=== RUN   TestAccAWSOpsworksInstance
--- PASS: TestAccAWSOpsworksInstance (99.89s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws99.911s
```
2017-01-02 20:35:31 +00:00
Chris Trotman ae3144a876 provider/aws: Add `most_recent` to the ebs_snapshot data source (#10986) 2017-01-02 13:48:23 +00:00
Michael S. Fischer af9505ffa2 aws_key_pair: Ensure key_name attribute is set
Ensure that the `key_name` attribute is available to `aws_key_pair`
resource dependents, even when the attribute is not specifically
set (i.e., when `key_name_prefix` or automatic naming is performed).

Fixes #10983.
2017-01-01 12:17:43 -08:00
Tim Gossett 39520ab568
implement CloudFront Lambda function associations 2016-12-31 20:51:30 -05:00
Kit Ewbank e8f4d002d9 provider/aws: Add 'aws_vpc_peering_connection' data source (#10913)
* Add 'aws_vpc_peering_connection' data source.

* Changes after code review.

* Add 'accepter' and 'requester' blocks to aws_vpc_peering_connection data source output attributes.
2016-12-30 00:30:51 +00:00
Ninir d126570712 provider/aws: Added a validation for security group rule types (#10864) 2016-12-30 00:26:01 +00:00
William Bowling 7faa755061 only wait for spot fleet instance termination if requested 2016-12-29 13:17:42 +11:00
Paul Stack e336d4e00b provider/aws: Set aws_autoscaling_policy metric_aggregation_type to be (#10904)
Computed

Fixes: #10887

In the Terraform documentation, we say the following:

```
metric_aggregation_type - (Optional) The aggregation type for the policy's metrics. Valid values are "Minimum", "Maximum", and "Average". Without a value, AWS will treat the aggregation type as "Average".
```

Therefore, because the parameter wasn't set as computed, we got a diff as follows:

```
~ aws_autoscaling_policy.scale
    metric_aggregation_type: "Average" => ""
```

With the change in place, we get the correct behaviour

```
% terraform plan
[WARN] /Users/stacko/Code/go/bin/terraform-provider-aws overrides an internal plugin for aws-provider.
  If you did not expect to see this message you will need to remove the old plugin.
  See https://www.terraform.io/docs/internals/internal-plugins.html
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan, but
will not be persisted to local or remote state storage.

aws_launch_configuration.launch: Refreshing state... (ID: config)
aws_autoscaling_group.asg: Refreshing state... (ID: asg)
aws_autoscaling_policy.scale: Refreshing state... (ID: scale)

No changes. Infrastructure is up-to-date. This means that Terraform
could not detect any differences between your configuration and
the real physical resources that exist. As a result, Terraform
doesn't need to do anything.
```
2016-12-28 23:30:43 +00:00
myoung34 dd807c79ff Add support for instance tenancy in `aws_opsworks_instance` (#10885) 2016-12-28 22:48:24 +00:00
Clint b6a54bb14f provider/aws: Guard against nil change output (#10798) 2016-12-28 16:45:07 +00:00
Ninir 5dbc66012e provider/aws: Reworked validateArn function to handle empty values (#10833) 2016-12-27 20:52:22 +00:00
James Nugent fce99df7fb Merge pull request #10871 from curtisallen/issue_10786
provider/aws: fix double base64 encode

Fixes #10786.
2016-12-27 14:44:36 -06:00
James Nugent 63dbfc2544 Merge pull request #10921 from Ninir/s3_replication_storage_class
provider/aws: Fixed the need of sending S3 Replication StorageClass when not set

Fixes #10909.
2016-12-27 14:39:12 -06:00
Conor Mongey dd187beda3 Fix typo in error code for aws_spot_fleet (#10928) 2016-12-27 16:26:20 +00:00
Ninir 88b3cc5b58 provider/aws: Fixed the need of sending S3 Replication StorageClass when not set 2016-12-24 11:47:04 +01:00
Curtis Allen ad565974ac fixes double base64 encode
Add a utility that ensures a byte array is not doubly base64 encoded
Fixes #10786
2016-12-20 17:47:05 -07:00
Clint 7998c3be92 Merge pull request #8622 from optimisticanshul/8604-snapshot-rds-password
Update rds password if provided while creating from snapshot
2016-12-19 13:59:48 -06:00
Paul Stack 1ff623a790 provider/aws: Support updating of aws_db_instance db_subnet_group_name (#10818)
Fixes: #10811

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDBInstance_subnetGroup'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/12/18 12:52:21 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSDBInstance_subnetGroup -timeout 120m
=== RUN   TestAccAWSDBInstance_subnetGroup
--- PASS: TestAccAWSDBInstance_subnetGroup (992.05s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	992.073s
```
2016-12-18 14:35:24 +00:00
Kit Ewbank ca183126c8 Add 'aws_iam_account_alias' data source. (#10804) 2016-12-18 14:17:19 +00:00
Harry Hull 2ebbf598cb Add aws verification checks to opsworks acceptance tests (#10813)
* Verify with aws api in opsworks resource acceptance tests
Fixes #6202

* Minor fix to resource_aws_opsworks_application_test.go
2016-12-18 11:55:40 +00:00
clint shryock 42efeb66db add missing runtime 2016-12-16 11:36:19 -06:00
clint shryock 45a7cc5afd more randomiztion for lambda tests 2016-12-16 10:42:37 -06:00
Ninir f96e45ba56 provider/aws: Deprecated aws_lambda_function nodejs runtime in favor of nodejs4.3 (#9724)
* provider/aws/lambda: Deprecated nodejs in favor of nodejs4.3

* Removed redundant type declarations in composite literals

* Added validation tests
2016-12-16 12:24:45 +00:00
Ivan Fuyivara 4d4ec6c0d1 provider/aws: Support for SES Configuration sets and Event Destinations (#10735)
* adding configuration set

* adding event destination

* adding test, all tests passing

* adding doccumentation
2016-12-16 11:46:39 +00:00
stack72 8efa37f7ff
Merge branch 'api_gateway_binary_media_types' of https://github.com/jmettes/terraform into jmettes-api_gateway_binary_media_types 2016-12-16 11:16:04 +00:00
Clint 7711952423 Merge pull request #9837 from Ninir/redshift_cluster_password
provider/aws: Redshift Cluster: Fix for master_username & password
2016-12-15 21:28:36 -06:00
Jonathan Mettes 0e6b2a4f9f Add support for binary media type to AWS API Gateway 2016-12-16 02:14:29 +00:00
Clint 75010e9112 Merge pull request #10771 from hashicorp/b-aws-test-fixes
provider/aws: More randomization so our tests can run in parallel
2016-12-15 16:36:37 -06:00
clint shryock 8d2e61e88d provider/aws: More randomization so our tests can run in parallel 2016-12-15 16:33:10 -06:00
Dan Thagard 82ef4b678d Drop alias from state file if missing from lambda. (#10759)
* Drop alias from state file if missing from lambda.

This commit fixes an issue where if you remove a AWS Lambda, the corresponding alias for that Lambda is also deleted.

* Added missing imports.

* Removed non-local reference to constant.
2016-12-15 15:33:38 -06:00
Clint 8371d3faab Merge pull request #10763 from Ninir/d-aws-source-ami-owners
provider/aws: Fixed the data source ami enforcing non-nil values
2016-12-15 14:35:29 -06:00
Ninir a8a37b8f84 provider/aws: Fixed the data source ami enforcing non-nil values 2016-12-15 19:18:57 +01:00
Clint 89c328aed4 Merge pull request #10733 from hashicorp/f-remove-deprecated-param-group
provider/aws: Removed deprecated parameter group from RDS Cluster
2016-12-14 16:32:36 -06:00
clint shryock 70b1f4e708 provider/aws: Bump EMR Cluster create timeout 2016-12-14 10:25:45 -06:00
clint shryock 4007fd2bc8 provider/aws: Removed deprecated parameter group from RDS Cluster 2016-12-14 10:08:11 -06:00
James Nugent a160d1cd69 provider/aws: Support eu-west-2 (#10470)
* provider/aws: Support eu-west-2

This is the new London region - we don't have access yet but several
enquiries have come from customers who do.

* provider/aws: Support eu-west-2 region

* Update hosted_zones.go
2016-12-14 09:33:58 +00:00
Kit Ewbank c7bf4fc8d3 Correct error message for 'aws_caller_identity' acceptance test. (#10712) 2016-12-14 09:33:06 +00:00
Clint 56b0e87f5e Merge pull request #10704 from Ninir/r-aws-sns_topic-protocols
provider/aws: Improved the SNS topic subscription protocols validation
2016-12-13 16:54:21 -06:00
Ninir 99be2d3280 provider/aws: Improved the SNS topic subscription protocols validation 2016-12-13 17:54:52 +01:00
Mathieu Herbert 3239138099 provider/aws: data source for AWS Hosted Zone (#9766)
* provider/aws: data source for AWS Hosted Zone

* add caller_reference, resource_record_set_count fields, manage private zone and trailing dot

* fix fmt

* update documentation, use string function in hostedZoneNamewq

* add vpc_id support

* add tags support

* add documentation for hosted zone data source tags support
2016-12-13 16:22:26 +00:00
Clint b2136beff2 Merge pull request #10702 from hashicorp/pr-10694
provider/aws: Save `iam_access_key` secret to state if no PGP key given (supersedes #10694)
2016-12-13 10:11:07 -06:00
clint shryock 72885c6736 provider/aws: Save secret to state in iam_access_key if pgp key not found 2016-12-13 09:32:04 -06:00
Ryan Hoegg 73213793ca provider/aws: Add aws_eip data source (#9833)
* provider/aws: Add the aws_eip data source

* Document the aws_eip data source on the website

* provider/aws: support query by public_ip for aws_eip data source
2016-12-13 12:09:21 +00:00
Kit Ewbank d3633398a7 provider/aws Add aws_vpc_endpoint_service data source (#10261)
* provider/aws Add aws_vpc_endpoint_services data source.

* Rename 'aws_vpc_endpoint_services' to 'aws_vpc_endpoint_service'.
2016-12-13 10:40:35 +00:00
Kazuma Watanabe 0134315148 enable DeleteOnTermination (#9922) 2016-12-13 10:38:05 +00:00
Mickaël Canévet 3ab5c630bd Don't remove secret, just deprecate it 2016-12-13 11:31:32 +01:00
Paul Stack 1113ed5fc7 provider/aws: Support MFA delete for s3 bucket versioning (#10020)
Fixes #7902

```
% make testacc TEST=./builtin/providers/aws
% TESTARGS='-run=TestAccAWSS3Bucket_'
% ✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/12/12 12:11:45 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSS3Bucket_
-timeout 120m
=== RUN   TestAccAWSS3Bucket_importBasic
--- PASS: TestAccAWSS3Bucket_importBasic (55.74s)
=== RUN   TestAccAWSS3Bucket_importWithPolicy
--- PASS: TestAccAWSS3Bucket_importWithPolicy (63.34s)
=== RUN   TestAccAWSS3Bucket_Notification
--- PASS: TestAccAWSS3Bucket_Notification (165.15s)
=== RUN   TestAccAWSS3Bucket_NotificationWithoutFilter
--- PASS: TestAccAWSS3Bucket_NotificationWithoutFilter (63.22s)
=== RUN   TestAccAWSS3Bucket_basic
--- PASS: TestAccAWSS3Bucket_basic (47.82s)
=== RUN   TestAccAWSS3Bucket_region
--- PASS: TestAccAWSS3Bucket_region (18.88s)
=== RUN   TestAccAWSS3Bucket_acceleration
--- PASS: TestAccAWSS3Bucket_acceleration (34.56s)
=== RUN   TestAccAWSS3Bucket_RequestPayer
--- PASS: TestAccAWSS3Bucket_RequestPayer (90.26s)
=== RUN   TestAccAWSS3Bucket_Policy
--- PASS: TestAccAWSS3Bucket_Policy (120.25s)
=== RUN   TestAccAWSS3Bucket_UpdateAcl
--- PASS: TestAccAWSS3Bucket_UpdateAcl (87.51s)
=== RUN   TestAccAWSS3Bucket_Website_Simple
--- PASS: TestAccAWSS3Bucket_Website_Simple (138.38s)
=== RUN   TestAccAWSS3Bucket_WebsiteRedirect
--- PASS: TestAccAWSS3Bucket_WebsiteRedirect (139.44s)
=== RUN   TestAccAWSS3Bucket_WebsiteRoutingRules
--- PASS: TestAccAWSS3Bucket_WebsiteRoutingRules (97.82s)
=== RUN   TestAccAWSS3Bucket_shouldFailNotFound
--- PASS: TestAccAWSS3Bucket_shouldFailNotFound (26.84s)
=== RUN   TestAccAWSS3Bucket_Versioning
--- PASS: TestAccAWSS3Bucket_Versioning (131.89s)
=== RUN   TestAccAWSS3Bucket_Cors
--- PASS: TestAccAWSS3Bucket_Cors (92.71s)
=== RUN   TestAccAWSS3Bucket_Logging
--- PASS: TestAccAWSS3Bucket_Logging (86.46s)
=== RUN   TestAccAWSS3Bucket_Lifecycle
--- PASS: TestAccAWSS3Bucket_Lifecycle (132.70s)
=== RUN   TestAccAWSS3Bucket_Replication
--- PASS: TestAccAWSS3Bucket_Replication (122.70s)
=== RUN   TestAccAWSS3Bucket_ReplicationExpectVersioningValidationError
--- PASS: TestAccAWSS3Bucket_ReplicationExpectVersioningValidationError (39.04s)
```
2016-12-12 22:34:03 +00:00
Ninir 16660a4f60 provider/aws: Fixed deletion of aws_api_gateway_base_path_mapping with empty path (#10177) 2016-12-12 22:09:25 +00:00
Ninir fc5b05ebc1 provider/aws: Added SQS FIFO queues (#10614) 2016-12-12 17:40:59 +00:00
Ninir 048a932abd provider/aws: Added Lambda function guard when needed attributes are not set (#10663) 2016-12-12 15:12:56 +00:00
Jan Schumann a01a93067f tests for #5907 (#10669) 2016-12-12 14:42:04 +00:00
Ninir 3f5e12ff7e provider/aws: Set the DBName when restoring from a snapshot (#10664) 2016-12-12 12:56:56 +00:00
Paul Stack c69e325a1a provider/aws: Add support for AWS Lightsail Domain (#10637)
```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSLightsailDomain_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/12/09 15:19:58 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSLightsailDomain_ -timeout 120m
=== RUN   TestAccAWSLightsailDomain_basic
--- PASS: TestAccAWSLightsailDomain_basic (16.28s)
=== RUN   TestAccAWSLightsailDomain_disappears
--- PASS: TestAccAWSLightsailDomain_disappears (12.71s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws29.015s
```
2016-12-09 17:56:48 +00:00
Clint e705cd9a93 Merge pull request #10635 from dougneal/import_vpc_peerconn_accepter_fix
provider/aws: aws_vpc_peering_connection: import fix
2016-12-09 11:50:55 -06:00
Tom Wilkie dd39296d6c Allow import of aws_security_groups with more than one source_security_group_id rule (#9477)
* Allow import of aws_security_groups with more than one source_security_group_id rule

* Add acceptable test for security group with multiple source rules.
2016-12-09 15:50:51 +00:00
Clint 5f765d9de6 Merge pull request #10624 from hashicorp/pr-9891
provider/aws: Add aws_snapshot_create_volume_permission resource (contd. #9891)
2016-12-09 08:43:18 -06:00
Clint 0766074289 Merge pull request #10583 from hashicorp/f-lightsail-key-pair
provider/aws: Add Lightsail Key Pair resource
2016-12-09 08:26:00 -06:00
Doug Neal 24baa38408 provider/aws: aws_vpc_peering_connection: import fix
When importing an `aws_vpc_peering_connection`, the code assumes that
the account under Terraform control is the initiator (requester) of the
VPC peering request. This holds true when the peering connection is
between two VPCs in the same account, or when the peering connection has
been initiated from the controlled account to another.

However, when the peering connection has been initiated from a foreign
account towards the account under management, importing the peering
connection into the statefile results in values of `peer_vpc_id` and
`vpc_id` being the opposite way round to what they should be, and in the
`peer_owner_id` being set to the managed account's ID rather than the
foreign account's ID.

This patch checks the Accepter and Requester Owner IDs against the AWS
connection's reported owner ID, and reverses the mapping if it is
determined that the VPC peering connection is owned by the foreign
account.
2016-12-09 12:05:06 +00:00
Eddy Hernandez 7e737dac62 Add support for AWS CA Central 1 Region (#10618)
* Add support for AWS CA Central 1 Region

* additional metadata for ca-central-1

* add elb metadata for ca-central-1
2016-12-09 10:35:07 +01:00
clint shryock 42057045ff refactor the test to use caller_identity data source, and new ebs_snapshot resource 2016-12-08 16:43:03 -06:00
Jeremy Asher 185ee439da add wait after AWS snapshot attr modification
This adds up to a 5 minute wait after issuing an add or remove request
to adjust a snapshot's createVolumePermission attribute.
2016-12-08 16:12:25 -06:00
Jeremy Asher f20d1c3caa WIP aws_snapshot_create_volume_permission tests 2016-12-08 16:12:24 -06:00
Jeremy Asher 7216185f0d implement aws_snapshot_create_volume_permission
This adds the new resource aws_snapshot_create_volume_permission which
manages the createVolumePermission attribute of snapshots.  This allows
granting an AWS account permissions to create a volume from a particular
snapshot.  This is often required to allow another account to copy a
private AMI.
2016-12-08 16:12:23 -06:00
clint shryock 97ac4bde16 implement name_prefix 2016-12-08 14:08:45 -06:00
clint shryock 1e8e83fa6a provider/aws: Encrypt aws_iam_access_key.secret with pgp
optionally encrypt the iam access key secret with a pgp key
2016-12-08 11:08:05 -06:00
Doug Neal 195b041cd5 Validate `effect` in aws_iam_policy_document data source (#10608)
AWS allows only the case-sensitive strings `Allow` and `Deny` to appear
in the `Effect` fields of IAM policy documents. Catch deviations from
this, including mis-casing, before hitting the API and generating an
error (the error is a generic 400 and doesn't indicate what part of the
policy doc is invalid).
2016-12-08 16:16:40 +01:00
Ninir 29f8af16a1 provider/aws: Added S3 Bucket replication (#10552) 2016-12-08 11:59:13 +01:00
Timon Wong 80afc6759b provider/aws: Add "no_device" support to ephemeral block devices (#10547)
Fixes #8455, #5390

This add a new `no_device` attribute to `ephemeral_block_device` block,
which allows users omit ephemeral devices from AMI's predefined block
device mappings, which is useful for EBS-only instance types.
2016-12-08 11:03:51 +01:00
Ninir 5e3477664d provider/aws: Forces the api gateway domain name certificates to recreate the resource (#10588) 2016-12-07 22:51:44 +01:00
Ninir 4b25837dd0 provider/aws: FIxed the api_gw_domain_name replace operation (#10179) 2016-12-07 21:47:20 +01:00
clint shryock 86bb969087 provider/aws: add aws_lightsail_key_pair 2016-12-07 11:13:47 -06:00
Andras Ferencz-Szabo 53ebbed8df Service role is not updated on AWS for a CodeDeploy deployment group (#9866)
Service role is not updated on AWS for a CodeDeploy deployment group
2016-12-07 13:34:58 +01:00
Raphael Randschau 2b711f77c8 feat/aws: add iam_server_certificate data source (#10558)
useful if you have an automatic process creating certs for you, e.g. let's
lambda
2016-12-07 11:40:53 +01:00
James Nugent 3177fc0765 provider/aws: Extract helper/encryption library
This commit extracts the GPG code used for aws_iam_user_login_profile
into a library that can be reused for other resources, and updates the
call sites appropriately.
2016-12-06 14:24:21 -06:00
Clint f8f4634858 Merge pull request #10492 from Ninir/lambda_env_removal
provider/aws: Fixed Lambda environment removal
2016-12-05 14:33:11 -06:00
Jan Schumann 9e293def6a provider/aws: Add opsworks rds db resource (#10294)
* add rds db for opsworks

* switched to stack in vpc

* implement update method

* add docs

* implement and document force new resource behavior

* implement retry for update and delete

* add test that forces new resource
2016-12-05 16:14:15 +00:00
Clint e477658832 Merge pull request #10473 from hashicorp/f-aws-lightsail-instance
provider/aws: Add Lightsail Instance
2016-12-05 08:39:17 -06:00
Daniel del Castillo 08da905374 aws-emr-cluster: Assign correct number of core instances (n-1) on update (#10529) 2016-12-05 14:17:29 +00:00
Evgeny Chuvpilo 8586e323dc
provider/aws: Add support for termination protection and autotermination to EMR. 2016-12-05 13:54:00 +00:00
Mitchell Hashimoto e014cf3d83 providers/aws: cloudfront distribution 404 should mark as gone (#10281) 2016-12-05 13:31:05 +00:00
Kit Ewbank 26d0525e82 Add new aws_vpc_endpoint_route_table_association resource (#10137)
* Add new aws_vpc_endpoint_route_table_association resource.

This commit adds a new resource which allows to a list of route tables to be
either added and/or removed from an existing VPC Endpoint. This resource would
also be complimentary to the existing `aws_vpc_endpoint` resource where the
route tables might not be specified (not a requirement for a VPC Endpoint to
be created successfully) during creation, especially where the workflow is
such where the route tables are not immediately known.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>

Additions by Kit Ewbank <Kit_Ewbank@hotmail.com>:

* Add functionality
* Add documentation
* Add acceptance tests
* Set VPC endpoint route_table_ids attribute to "Computed"

* Changes after review - Set resource ID in create function.

* Changes after code review by @kwilczynski:
* Removed error types and simplified the error handling in 'resourceAwsVPCEndpointRouteTableAssociationRead'
* Simplified logging in 'resourceAwsVPCEndpointRouteTableAssociationDelete'
2016-12-05 12:55:37 +00:00
Ninir c250c10d4e Force the master username & password to be defined when not in a restore mode 2016-12-04 19:04:26 +01:00
clint shryock 44ffe71695 provider/aws: Add Lightsail Instance
Adds initial support for AWS Lightsail Instances
2016-12-02 16:35:57 -06:00
Ninir 615da28b6e provider/aws: Fixed Lambda environment removal 2016-12-02 14:36:55 +01:00
Ninir 1d090eb1ab provider/aws: Added s3 bucket region attribute management (#10482) 2016-12-02 14:22:47 +02:00
Jan Schumann 2e83eb1cfe fix #9104 (#10394) 2016-12-02 13:53:06 +02:00
Jan Schumann b8caddda21 provider/aws resource_aws_opsworks_application does not accept document_root parameter (#10477)
* switched to stack in vpc

* validate also on update

* validate attributes based on app type
2016-12-02 13:45:10 +02:00
Paul Stack ac257b8048 provider/aws: Fix aws_iam_role_test config (#10464)
```
% make testacc TEST=./builtin/providers/aws
% TESTARGS='-run=TestAccAWSRole_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/12/01 17:17:31 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSRole_
-timeout 120m
=== RUN   TestAccAWSRole_basic

--- PASS: TestAccAWSRole_basic (15.38s)
=== RUN   TestAccAWSRole_namePrefix
--- PASS: TestAccAWSRole_namePrefix (14.89s)
=== RUN   TestAccAWSRole_testNameChange
--- PASS: TestAccAWSRole_testNameChange (34.43s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws64.729s
```
2016-12-01 18:22:05 +02:00