Commit Graph

6232 Commits

Author SHA1 Message Date
Paul Stack 54459900c5 [WIP] provider/azurerm: Bump sdk version to 7.0.1 (#10458)
* provider/azurerm: Bump sdk version to 7.0.1

* Fixing the build (#10489)

* Fixing the broken tests (#10499)

* Updating the method signatures to match (#10533)
2016-12-06 08:39:47 +00:00
Tom Straub 20003b2744 provider/azurerm support `license_type` virtual_machine property for Windows machines. (#10539)
* Added license_type to Azure VirtualMachineProperties call.

* Updated websit documentation.

* Added validation for license_type

* Added acceptance test

* Clarified documentation.
2016-12-06 08:38:10 +00:00
Cameron Childress c5e63106b5 Force a recreate if the numbers for the AS are changed. (#10545) 2016-12-06 08:34:25 +00:00
zimbatm 01876ef415
provider/fastly: add ssl_hostname option
Fastly will fail if the user sets the port to 443, ssl_check_cert is set
to true and the ssl_hostname is not provided.
2016-12-06 08:28:37 +00:00
Mitchell Hashimoto 4b1d9cfd7d
communicator/ssh: don't share rand object to guarantee unique values
Fixes #10463

I'm really surprised this flew under the radar for years...

By having unique PRNGs, the SSH communicator could and would
generate identical ScriptPaths and two provisioners running in parallel
could overwrite each other and execute the same script. This would
happen because they're both seeded by the current time which could
potentially be identical if done in parallel...

Instead, we share the rand now so that the sequence is guaranteed
unique. As an extra measure of robustness, we also multiple by the PID
so that we're also protected against two processes at the same time.
2016-12-06 00:21:49 -08:00
Paul Tyng 15cde73000 Add pagerduty_user data source (#10541) 2016-12-05 22:42:58 +00: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
Martin Atkins e772b45970 "external" data source, for integrating with external programs (#8768)
* "external" provider for gluing in external logic

This provider will become a bit of glue to help people interface external
programs with Terraform without writing a full Terraform provider.

It will be nowhere near as capable as a first-class provider, but is
intended as a light-touch way to integrate some pre-existing or custom
system into Terraform.

* Unit test for the "resourceProvider" utility function

This small function determines the dependable name of a provider for
a given resource name and optional provider alias. It's simple but it's
a key part of how resource nodes get connected to provider nodes so
worth specifying the intended behavior in the form of a test.

* Allow a provider to export a resource with the provider's name

If a provider only implements one resource of each type (managed vs. data)
then it can be reasonable for the resource names to exactly match the
provider name, if the provider name is descriptive enough for the
purpose of the each resource to be obvious.

* provider/external: data source

A data source that executes a child process, expecting it to support a
particular gateway protocol, and exports its result. This can be used as
a straightforward way to retrieve data from sources that Terraform
doesn't natively support..

* website: documentation for the "external" provider
2016-12-05 17:24:57 +00: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
Joe Topjian 1c9853ec1b provider/openstack: Fix Ordering of Port Allowed Address Pairs (#10250)
This commit changes allowed_address_pairs from a TypeList to a TypeSet
allowing for arbitrary ordering. This solves the issue where a user
specifies an address pair one way and OpenStack returns a different
order.
2016-12-05 15:36:37 +00:00
John Engelman 243ecf3b4f [Provider] Rancher (#9173)
* Vendor Rancher Go library.

* Implement Rancher Provider.

Starting implementation taken from
https://github.com/platanus/terraform-provider-rancher

Commits from jidonoso@gmail.com and raphael.pinson@camptocamp.com
2016-12-05 15:29:41 +00:00
stack72 9ffb39b44e
Merge branch 'master' of github.com:hashicorp/terraform 2016-12-05 15:07:13 +00:00
stack72 63aa6a1fcd
provider/azurerm: removing azurerm_virtual_machine data_disk disk_size_in_gb 2016-12-05 15:05:21 +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
stack72 f7aea2f447
Merge branch 'master' of https://github.com/ckarlsen84/terraform into ckarlsen84-master 2016-12-05 14:23:26 +00: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
Brendan Shaklovitz 122e2f8170 provider/datadog: Improve datadog timeboard support (#10027)
* Update to latest version of go-datadog-api

* Updates to  latest go-datadog-api version, which adds more complete
timeboard support.

* Add more complete timeboard support

* Adds in support for missing timeboard fields, so now we can have nice
things like conditional formats and more.

* Document new fields in datadog_timeboard resource

* Add acceptance test for datadog timeboard changes
2016-12-05 13:16:47 +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
Michael Kuzmin 05145dba19 provider/docker: Upload files into container before first start (#9520)
* Create uploads section for docker containers

* Upload a single file, load its content from state
2016-12-05 11:06:34 +00:00
Paddy e1a5805833 Fix instance/template metadata support
Update our instance template to include metadata_startup_script, to
match our instance resource. Also, we've resolved the diff errors around
metadata.startup-script, and people want to use that to create startup
scripts that don't force a restart when they're changed, so let's stop
disallowing it.

Also, we had a bunch of calls to `schema.ResourceData.Set` that ignored
the errors, so I added error handling for those calls. It's mostly
bundled with this code because I couldn't be sure whether it was the
root of bugs or not, so I took care of it while addressing the startup
script issue.
2016-12-05 02:45:28 -08:00
Otto Jongerius 5a4578edf6 provider/datadog #9026: Make thresholds optional. (#10526) 2016-12-05 09:52:59 +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
Joe Topjian b2f9a3a6fd provider/openstack: Detect Region for Importing Resources (#10509)
* provider/openstack: Detect Region for Importing Resources

This commit changes the way the OpenStack region is detected and set.
Any time a region is required, the region attribute will first be
checked. Next, the OS_REGION_NAME environment variable will be checked.
While schema.EnvDefaultFunc handles this same situation, it is not
applicable when importing resources.

* provider/openstack: No longer ignore region in importing tests

* provider/openstack: Network and Subnet Import Fixes

This commit fixes the OpenStack Network and Subnet resources so that
importing of those resources is successful.
2016-12-04 14:24:07 +00: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
Dana Hoffman 0e03f59e4a remove loadBalancingScheme as an option in RegionBackendService since it can only be INTERNAL 2016-12-01 12:27:36 -08:00
Dana Hoffman fd2b1fcbd6 add one more test for updating a health check 2016-12-01 12:27:35 -08:00
Dana Hoffman 77f0ef4fc1 fix bugs in health check and its tests 2016-12-01 12:27:35 -08:00
Dana Hoffman 20ee56be07 Add the other HealthCheck types 2016-12-01 12:27:34 -08:00
Dana Hoffman adafa722e7 clean up RegionBackendService and tests 2016-12-01 12:27:34 -08:00
Dana Hoffman 39809fca76 use v1 apis instead of beta 2016-12-01 12:27:33 -08:00
Dana Hoffman a04ed894d1 First set of changes to enable internal load balancing using beta apis 2016-12-01 11:14:21 -08:00
Paddy 7054fdfa13 providers/google: make projects importable.
This change doesn't make much sense now, as projects are read-only
anyways, so there's not a lot that importing really does for you--you
can already reference pre-existing projects just by defining them in
your config.

But as we discussed #10425, this change made more and more sense. In a
world where projects can be created, we can no longer reference
pre-existing projects just by defining them in config. We get that
ability back by making projects importable.
2016-12-01 10:38:27 -08:00
Paddy 973a46c5df Merge pull request #10387 from bpineau/google_session_affinity
provider/google: allow session affinity for compute_backend_service
2016-12-01 10:18:27 -08: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
stack72 4e0ebfde3f
provider/aws: removal of the duplicate import aws_iam_instance_profile test 2016-12-01 16:55:53 +02:00
stack72 a4dba89553
provider/aws: Fixing the broken build of the aws_iam_policy resource 2016-12-01 16:50:28 +02:00
stack72 7497a295b8
provider/aws: Fixing the broken build of the aws_iam_role resource 2016-12-01 16:46:01 +02:00
stack72 8369ab44ec
provider/aws: Fixing the broken build of the aws_iam_policy resource 2016-12-01 16:44:40 +02:00
Tom Wilkie 71e8cffeea
Allow importing of aws_iam_role, aws_iam_role_policy, aws_iam_policy and aws_iam_instance_profile 2016-12-01 16:41:23 +02:00
Raymond Fallon 7b672d4656 Automatic Rollback of CodeDeploy deployments and CloudWatch Alarms for a Deployment Group (#9039)
* provider/aws: Add DeploymentRollback as a valid TriggerEvent type

* provider/aws: Add auto_rollback_configuration to aws_codedeploy_deployment_group

* provider/aws: Document auto_rollback_configuration

  - part of aws_codedeploy_deployment_group

* provider/aws: Support removing and disabling auto_rollback_configuration

  - part of aws_codedeploy_deployment_group resource
  - when removing configuration, ensure events are removed
  - when disabling configuration, preserve events in case configuration is re-enabled

* provider/aws: Add alarm_configuration to aws_codedeploy_deployment_group

* provider/aws: Document alarm_configuration

  - part of aws_codedeploy_deployment_group

* provider/aws: Support removing alarm_configuration

  - part of aws_codedeploy_deployment_group resource
  - disabling configuration doesn't appear to work...

* provider/aws: Refactor auto_rollback_configuration tests

  - Add create test
  - SKIP failing test for now
  - Add tests for build & map functions

* provider/aws: Refactor new aws_code_deploy_deployment_group tests

  - alarm_configuration and auto_rollback_configuration only
  - add assertions to deployment_group basic test
  - rename config funcs to be more easy to read
  - group public tests together

* provider/aws: A max of 10 alarms can be added to a deployment group.

  - aws_code_deploy_deployment_group.alarm_configuration.alarms
  - verified this causes test failure with expected exception

* provider/aws: Test disabling alarm_configuration and auto_rollback_configuration

  - the tests now pass after rebasing the latest master branch
2016-12-01 16:12:14 +02:00
Tom Wilkie 8029931086 Do not return a root device for instance store backed AMIs. (#9483)
* Do not return a root device for instance store backed AMIs.

* Add root EC2 instance store acceptance test.
2016-12-01 15:53:14 +02:00
Colin Woodbury a5f8352e11 Increase `aws_emr_cluster` timeout to 75 minutes (#10444) 2016-12-01 12:05:40 +02:00
Paul Stack 83abf5b16a provider/aws: Support import of aws_iam_instance_profile (#10436)
Fixes #10341

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSIAMInstanceProfile_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/30 14:32:59 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSIAMInstanceProfile_ -timeout 120m
=== RUN   TestAccAWSIAMInstanceProfile_importBasic
--- PASS: TestAccAWSIAMInstanceProfile_importBasic (20.22s)
=== RUN   TestAccAWSIAMInstanceProfile_basic
--- PASS: TestAccAWSIAMInstanceProfile_basic (18.71s)
=== RUN   TestAccAWSIAMInstanceProfile_namePrefix
--- PASS: TestAccAWSIAMInstanceProfile_namePrefix (18.58s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws57.535s
```
2016-12-01 09:01:15 +02:00
Benjamin Pineau f2a3c5da82 provider/google: allow session affinity for compute_backend_service
Google's Backend Services gives users control over the session affinity modes.
Let's allow Terraform users to leverage this option.
We don't change the default value ("NONE", as provided by Google).
2016-11-30 23:50:50 +01:00
Anshul Sharma a886b630a0 IPv6 Support To Cloudfront (#10332)
* Added IPv6 Support To Cloudfront

* Added IPv6 docs to cloudfront
2016-11-30 14:13:30 +02:00
Ninir 5481e9ecb3 provider/aws: Enforced kms_key_* attributes to be ARNs (#10356)
* Added kms_key_* validation to force ARNs

* Added Redshift Cluster KMS key test

* Added cloudtrail kms key test

* Added EBS volume kms key

* Added Elastic Transcoder Pipeline kms key arn test
2016-11-30 13:50:26 +02:00
Lee Johnson d203dcf6a5 simplifying tests by removing tests and test data that is no longer needed 2016-11-29 16:03:58 -05:00
Lee Johnson c62f6a8018 Merge remote-tracking branch 'origin/master' into statuscake_adding_contact_group 2016-11-29 15:53:19 -05:00
Lee Johnson 3ff92224d2 Merge remote-tracking branch 'origin/master' into statuscake_adding_contact_group 2016-11-29 15:27:04 -05:00
Sander van Harmelen a3c6fec4e6 Properly support secundary IP addresses (#10420)
And remove the deprecated `network_id` field.
2016-11-29 20:48:38 +01:00
Peter McAtominey a4054c999e provider/azurerm: create common schema for location field, add diff suppress (#10409) 2016-11-29 15:54:00 +00:00
cagriy 8cdafe0508 typo corrected in structure.go (#10415) 2016-11-29 15:49:34 +00:00
Mathieu Herbert aec4e56f68
provider/aws: data source for AWS Route Table 2016-11-28 18:07:38 +00:00
Peter McAtominey 3bb9312d19 provider/azurerm: support import of routes, fix route_table (#10389)
* provider/azurerm: support import of route

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMRoute_import -timeout 120m
=== RUN   TestAccAzureRMRoute_importBasic
--- PASS: TestAccAzureRMRoute_importBasic (166.99s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	167.066s

* provider/azurerm: fix route_table not setting routes

The resource wasn't actually setting the routes in the create/update method,
this went unnoticed as it also didn't read the routes array back to state.

Fixes #10316

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMRouteTable -timeout 120m
=== RUN   TestAccAzureRMRouteTable_basic
--- PASS: TestAccAzureRMRouteTable_basic (122.96s)
=== RUN   TestAccAzureRMRouteTable_disappears
--- PASS: TestAccAzureRMRouteTable_disappears (121.12s)
=== RUN   TestAccAzureRMRouteTable_withTags
--- PASS: TestAccAzureRMRouteTable_withTags (136.01s)
=== RUN   TestAccAzureRMRouteTable_multipleRoutes
--- PASS: TestAccAzureRMRouteTable_multipleRoutes (155.44s)
PASS
ok   github.com/hashicorp/terraform/builtin/providers/azurerm    535.612s

* provider/azurerm: support import of route_table

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMRouteTable_import -timeout 120m
=== RUN   TestAccAzureRMRouteTable_importBasic
--- PASS: TestAccAzureRMRouteTable_importBasic (121.90s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	121.978s
2016-11-28 17:35:55 +00:00
Andy Lindeman 5ddf83907c provider/github: supports importing resources (#10382)
```
=== RUN   TestProvider
--- PASS: TestProvider (0.00s)
=== RUN   TestProvider_impl
--- PASS: TestProvider_impl (0.00s)
=== RUN   TestAccGithubIssueLabel_basic
--- PASS: TestAccGithubIssueLabel_basic (0.91s)
=== RUN   TestAccGithubIssueLabel_importBasic
--- PASS: TestAccGithubIssueLabel_importBasic (0.41s)
=== RUN   TestAccGithubMembership_basic
--- PASS: TestAccGithubMembership_basic (0.84s)
=== RUN   TestAccGithubMembership_importBasic
--- PASS: TestAccGithubMembership_importBasic (0.53s)
=== RUN   TestAccGithubRepositoryCollaborator_basic
--- PASS: TestAccGithubRepositoryCollaborator_basic (0.64s)
=== RUN   TestAccGithubRepositoryCollaborator_importBasic
--- PASS: TestAccGithubRepositoryCollaborator_importBasic (0.74s)
=== RUN   TestAccGithubRepository_basic
--- PASS: TestAccGithubRepository_basic (1.54s)
=== RUN   TestAccGithubRepository_importBasic
--- PASS: TestAccGithubRepository_importBasic (0.77s)
=== RUN   TestAccGithubTeamMembership_basic
--- PASS: TestAccGithubTeamMembership_basic (1.59s)
=== RUN   TestAccGithubTeamMembership_importBasic
--- PASS: TestAccGithubTeamMembership_importBasic (0.95s)
=== RUN   TestAccGithubTeamRepository_basic
--- PASS: TestAccGithubTeamRepository_basic (1.45s)
=== RUN   TestAccGithubTeamRepository_importBasic
--- PASS: TestAccGithubTeamRepository_importBasic (0.75s)
=== RUN   TestAccCheckGetPermissions
--- PASS: TestAccCheckGetPermissions (0.00s)
=== RUN   TestAccGithubTeam_basic
--- PASS: TestAccGithubTeam_basic (0.79s)
=== RUN   TestAccGithubTeam_importBasic
--- PASS: TestAccGithubTeam_importBasic (0.54s)
=== RUN   TestAccGithubUtilRole_validation
--- PASS: TestAccGithubUtilRole_validation (0.00s)
=== RUN   TestAccGithubUtilTwoPartID
--- PASS: TestAccGithubUtilTwoPartID (0.00s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/github 12.455s
```
2016-11-28 17:30:24 +00:00
Alexander Kyxap f993f0e70e Added 'connect_timeout' argument to provider 'postgresql' (#10380) 2016-11-28 16:52:10 +00:00
James Nugent aa8c2ac587 provider/aws: Randomize names for Parameter Group tests
This should allow tests to run concurrently.
2016-11-25 21:48:54 +00:00
Paul Stack e0b94e4dc4 provider/azurerm: Removing the commented out acceptance tests as they were killing the test runner (#10368) 2016-11-25 15:55:00 +00:00
James Nugent 08b860290a provider/aws: Generate random names for Beanstalk tests resources (#10367)
* provider/aws: Generate name for TestAccElasticBeanstalkApplicationImport

This allows tests to run concurrently.

* provider/aws: Generate names for TestAWSElasticBeanstalkEnvironment_importBasic

This allows tests to run concurrently.
2016-11-25 15:44:41 +00:00
Paul Stack b77dac5ab8 provider/aws: Randomize redshift subnet group test names (#10366) 2016-11-25 15:37:19 +00:00
Paul Stack 446afbc241 provider/azurerm: Randomizing the test names for network interface card (#10364) 2016-11-25 14:34:05 +00:00
Paul Stack 3d3609c271 provider/aws: Fixing up acceptance tests after seeing concurrent (#10362)
failures

* codecommit
* cloudwatch_logs
2016-11-25 12:50:19 +00:00
stack72 bbf133fd21
provider/azurerm: Randomizing the ARM security group acceptance tests 2016-11-24 22:11:17 +00:00
stack72 71f376f7a5
provider/azurerm: Randomizing the ARM security rule acceptance tests 2016-11-24 21:54:59 +00:00
stack72 16a725b33f
provider/azurerm: Randomizing the ARM acceptance tests 2016-11-24 21:53:19 +00:00
Peter McAtominey 20efd54995 provider/azurerm: set ForceNew for storage image and OS disk of virtual_machine (#10340)
TF_ACC=1 go test ./builtin/providers/azurerm -v -run "TestAccAzureRMVirtualMachine_change" -timeout 120m
=== RUN   TestAccAzureRMVirtualMachine_changeStorageImageReference
--- PASS: TestAccAzureRMVirtualMachine_changeStorageImageReference (937.49s)
=== RUN   TestAccAzureRMVirtualMachine_changeOSDiskVhdUri
--- PASS: TestAccAzureRMVirtualMachine_changeOSDiskVhdUri (1187.81s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	2125.317s
2016-11-24 15:22:50 +00:00
Dan Everton 3be29ab5d0 Handle empty Lambda environment. (#10306)
The Lambda environment will be nil if the function has never had an
environment applied. Fixes #10302
2016-11-23 18:36:16 +02:00
Mitchell Hashimoto 68c96e0ce5 Merge pull request #10297 from hashicorp/b-template-path
providers/template: disallow file paths in `template`
2016-11-23 08:27:56 -08:00
Kit Ewbank 7319968f5f Skip VPC endpoint routes when removing default route table's routes. (#10303) 2016-11-23 18:12:59 +02:00
Joe Topjian 1aff30dd5e Merge pull request #10260 from jtopjian/openstack-compute-volume-attach
provider/openstack: openstack_compute_volume_attach_v2 resource
2016-11-22 20:43:59 -07:00
clint shryock 2eb132c55a provider/aws: Patch issue with enable dns support 2016-11-22 13:44:44 -06:00
Mitchell Hashimoto 485455b2f2
providers/template: disallow file paths in `template`
Fixes #8660

This disallows file paths in `template`. This already had a deprecation
warning so we're just removing that.
2016-11-22 10:23:58 -08:00
Joe Topjian d16ba26495 Merge pull request #10259 from jtopjian/openstack-blockstorage-volume-attach
provider/openstack: openstack_blockstorage_volume_attach_v2 resource
2016-11-22 09:28:31 -07:00
Joe Topjian ab0b171b33 Merge pull request #9943 from jtopjian/openstack-swauth
provider/openstack: Add Swauth/Swift Authentication
2016-11-22 08:40:56 -07:00
Joe Topjian 4cc46937e8 provider/openstack: blockstorage volume attach code review updates 2016-11-22 15:27:23 +00:00
Michael Kuzmin c1a9a0c766 provider/docker: authentication via values instead of files (#10151)
* Docker authentication via values

* Rename parameters to ca_material, cert_material, and key_material. Add environment variables.
2016-11-22 14:18:09 +02:00
Peter McAtominey e3e8261857 provider/azurerm: enable import of more resources (#10195)
* provider/azurerm: support import of virtual_machine

TF_ACC=1 go test ./builtin/providers/azurerm -v -run "TestAccAzureRMVirtualMachine_(basic|import)" -timeout 120m
=== RUN   TestAccAzureRMVirtualMachine_importBasic
--- PASS: TestAccAzureRMVirtualMachine_importBasic (561.08s)
=== RUN   TestAccAzureRMVirtualMachine_basicLinuxMachine
--- PASS: TestAccAzureRMVirtualMachine_basicLinuxMachine (677.49s)
=== RUN   TestAccAzureRMVirtualMachine_basicLinuxMachine_disappears
--- PASS: TestAccAzureRMVirtualMachine_basicLinuxMachine_disappears (674.21s)
=== RUN   TestAccAzureRMVirtualMachine_basicWindowsMachine
--- PASS: TestAccAzureRMVirtualMachine_basicWindowsMachine (1105.18s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	3017.970s

* provider/azurerm: support import of servicebus_namespace

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMServiceBusNamespace_import -timeout 120m
=== RUN   TestAccAzureRMServiceBusNamespace_importBasic
--- PASS: TestAccAzureRMServiceBusNamespace_importBasic (345.80s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	345.879s

* provider/azurerm: document import of servicebus_topic and servicebus_subscription

* provider/azurerm: support import of dns record resources

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMDns[A-z]+Record_importBasic -timeout 120m
=== RUN   TestAccAzureRMDnsARecord_importBasic
--- PASS: TestAccAzureRMDnsARecord_importBasic (102.84s)
=== RUN   TestAccAzureRMDnsAAAARecord_importBasic
--- PASS: TestAccAzureRMDnsAAAARecord_importBasic (100.59s)
=== RUN   TestAccAzureRMDnsCNameRecord_importBasic
--- PASS: TestAccAzureRMDnsCNameRecord_importBasic (98.94s)
=== RUN   TestAccAzureRMDnsMxRecord_importBasic
--- PASS: TestAccAzureRMDnsMxRecord_importBasic (107.30s)
=== RUN   TestAccAzureRMDnsNsRecord_importBasic
--- PASS: TestAccAzureRMDnsNsRecord_importBasic (98.55s)
=== RUN   TestAccAzureRMDnsSrvRecord_importBasic
--- PASS: TestAccAzureRMDnsSrvRecord_importBasic (100.19s)
=== RUN   TestAccAzureRMDnsTxtRecord_importBasic
--- PASS: TestAccAzureRMDnsTxtRecord_importBasic (97.49s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	706.000s

* provider/azurerm: support import of cdn_endpoint, document profile import

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMCdnEndpoint_import -timeout 120m
=== RUN   TestAccAzureRMCdnEndpoint_importWithTags
--- PASS: TestAccAzureRMCdnEndpoint_importWithTags (207.83s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	207.907s

* provider/azurerm: support import of sql_server, fix sql_firewall import

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMSql[A-z]+_importBasic -timeout 120m
=== RUN   TestAccAzureRMSqlFirewallRule_importBasic
--- PASS: TestAccAzureRMSqlFirewallRule_importBasic (153.72s)
=== RUN   TestAccAzureRMSqlServer_importBasic
--- PASS: TestAccAzureRMSqlServer_importBasic (119.83s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	273.630s
2016-11-22 14:13:11 +02:00
Robert Rudduck 9a70b6f482 Check storage uri for nil. (#10283) 2016-11-22 13:39:35 +02:00
Masayuki Morita f85e0b7249 Add JSON validation to the aws_iam_policy resource (#10239)
Although the aws_iam_policy has a problem of normalization (refs #8350),
I think it would be useful simply to add JSON syntax validation.
I wasted a lot of time with JSON syntax errors.

Validate the aws_iam_policy using the validateJsonString helper.
2016-11-22 13:35:15 +02:00
Ninir b52813b639 provider/aws: added auto_minor_version_upgrade on aws_rds_cluster_instance (#10284) 2016-11-22 13:33:01 +02:00
Joe Topjian 74189c5211 provider/openstack: Add Swauth/Swift Authentication
This commit adds the ability to authenticate with Swauth/Swift. This can
be used in Swift-only environments that do not have a Keystone service
for authentication.
2016-11-22 04:26:06 +00:00
clint shryock dede6f7302 provider/aws: Reformat and detect drift for Lambda VPC, environment 2016-11-21 17:10:32 -06:00
Ninir ab9059564c provider/aws: Added Lambda Environment configuration 2016-11-21 22:23:39 +01:00
James Bardin e3ef8e6f8a Merge pull request #10228 from hashicorp/jbardin/map-crash
ResourceConfig.get should never return (nil, true)
2016-11-21 12:01:30 -05:00
Paul Stack b3fad6a68c provider/aws: Addition of suspended_processes to aws_autoscaling_group (#10096)
Fixes #8954

Addition of the support of autoScaling group suspended_processes
2016-11-21 17:02:20 +02:00
Paul Stack 7fde952d02 provider/aws: New Resource aws_ebs_snapshot (#10017)
* provider/aws: Add ability to create aws_ebs_snapshot

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEBSSnapshot_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/10 14:18:36 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEBSSnapshot_
-timeout 120m
=== RUN   TestAccAWSEBSSnapshot_basic
--- PASS: TestAccAWSEBSSnapshot_basic (31.56s)
=== RUN   TestAccAWSEBSSnapshot_withDescription
--- PASS: TestAccAWSEBSSnapshot_withDescription (189.35s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws220.928s
```

* docs/aws: Addition of the docs for aws_ebs_snapshot resource

* provider/aws: Creation of shared schema funcs for common AWS data source
patterns

* provider/aws: Create aws_ebs_snapshot datasource

Fixes #8828

This data source will use a number of filters, owner_ids, snapshot_ids
and restorable_by_user_ids in order to find the correct snapshot. The
data source has no real use case for most_recent and will error on no
snapshots found or greater than 1 snapshot found

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEbsSnapshotDataSource_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/10 14:34:33 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSEbsSnapshotDataSource_ -timeout 120m
=== RUN   TestAccAWSEbsSnapshotDataSource_basic
--- PASS: TestAccAWSEbsSnapshotDataSource_basic (192.66s)
=== RUN   TestAccAWSEbsSnapshotDataSource_multipleFilters
--- PASS: TestAccAWSEbsSnapshotDataSource_multipleFilters (33.84s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws226.522s
```

* docs/aws: Addition of docs for the aws_ebs_snapshot data source

Adds the new resource `aws_ebs_snapshot`
2016-11-21 12:40:22 +02:00
Chris Marchesi 67d162a126 provider/aws: aws_autoscaling_group ALB target group support (#10243)
This update adds ALB support to the
wait_for_elb_capacity/min_elb_capacity options. Target groups are
handled in nearly the same way as Classic ELBs, so the change should be
transparent. This supports both ALB target groups and classic ELBs being
attached to the ASG at the same time.
2016-11-21 11:50:58 +02:00
Kit Ewbank 7330d65678 provider/aws Return service CIDR blocks from aws_vpc_endpoint resource. (#10254) 2016-11-21 10:43:56 +02:00
Chris Marchesi 4845f8de39 provider/aws: Add aws_alb data source (#10196)
* provider/aws: Add aws_alb data source

This adds the aws_alb data source for getting information on an AWS
Application Load Balancer.

The schema is nearly the same as the resource of the same name, with
most of the resource population logic de-coupled into its own function
so that they can be shared between the resource and data source.

* provider/aws: aws_alb data source language revisions

 * Multiple/zero result error slightly updated to be a bit more
   specific.
 * Fixed relic of the copy of the resource docs (resource -> data
   source)
2016-11-21 10:27:44 +02:00
Richard Henning 2a5e1d400d provider/aws: Remove IAM user's MFA devices with `force_destroy` #5908 (#10262)
When `force_destroy` was specifed on an `aws_iam_user` resource, only IAM
access keys and the login profile were destroyed. If a multi-factor auth
device had been activated for that user, deletion would fail as follows:

```
* aws_iam_user.testuser1: Error deleting IAM User testuser1: DeleteConflict: Cannot delete entity, must delete MFA device first.
    status code: 409, request id: aa41b1b7-ac4d-11e6-bb3f-3b4c7a310c65
```

This commit iterates over any of the user's MFA devices and deactivates
them before deleting the user. It follows a pattern similar to that used
to remove users' IAM access keys before deletion.

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSUser_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/20 17:09:00 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSUser_ -timeout 120m
=== RUN   TestAccAWSUser_importBasic
--- PASS: TestAccAWSUser_importBasic (5.70s)
=== RUN   TestAccAWSUser_basic
--- PASS: TestAccAWSUser_basic (11.12s)
PASS
ok  	github.com/rhenning/terraform/builtin/providers/aws	20.840s
```
2016-11-21 10:17:27 +02:00
Joe Topjian 24d7ada0e4 provider/openstack: openstack_compute_volume_attach_v2 resource
This commit adds the openstack_compute_volume_attach_v2 resource. This
resource enables a volume to be attached to an instance by using the
OpenStack Compute (Nova) v2 volumeattach API.
2016-11-20 21:22:07 +00:00
Joe Topjian 672d4d20d7 provider/openstack: openstack_blockstorage_volume_attach_v2 resource
This commit adds the openstack_blockstorage_volume_attach_v2 resource. This
resource enables a volume to be attached to an instance by using the OpenStack
Block Storage (Cinder) v2 API.
2016-11-20 21:19:11 +00:00
Kit Ewbank fd8d41f6a5 Add note to aws_security_group data source describing the default security group for a VPC. (#10247)
Add a corresponding acceptance test.
2016-11-20 16:28:11 +02:00
Kit Ewbank 3255921b6e aws_prefix_list data source - Add ability to select PL by name. (#10248) 2016-11-20 16:21:55 +02:00
Mitchell Hashimoto 4406e27eaa
providers/nomad: use DefaultConfig to intialize all fields 2016-11-19 10:20:54 -08:00
Evan Brown d357e75201 Merge pull request #10117 from cblecker/f-gke-node-scopes
provider/google: Add support for scope aliases to google_container_cluster
2016-11-18 20:19:26 -08:00
Christian Karlsen 50b859ba9a provider/azurerm: make DiskSizeGB optional for data disks 2016-11-18 23:08:49 +01:00
James Bardin 68ba2d6ff0 ResourceConfig.get should never return (nil, true)
Fixes a case where ResourceConfig.get inadvertently returns a nil value.

Add an integration test where assigning a map to a list via
interpolation would panic.
2016-11-18 16:24:40 -05:00
Paul Stack dc0cb70e95 provider/github: Creating a github repository before adding a label (#10213) 2016-11-18 13:38:46 +02:00
Ian L f584d53ba9 provider/github: add GitHub labels resource (#10142)
* provider/github: add GitHub labels resource

Provides a GitHub issue label resource.

This resource allows easy management of issue labels for an
organisation's repositories. A name, and a color can be set.
These attributes can be updated without creating a new resource.

* provider/github: add documentation for GitHub issue labels resource
2016-11-18 13:24:37 +02:00
Chris Marchesi 3ac05a539b provider/aws: Add aws_alb_listener data source (#10181)
* provider/aws: Add aws_alb_listener data source

This adds the aws_alb_listener data source to get information on an AWS
Application Load Balancer listener.

The schema is slightly modified (only option-wise, attributes are the
same) and we use the aws_alb_listener resource read function to get the
data.

Note that the HTTPS test here may fail due until
hashicorp/terraform#10180 is merged.

* provider/aws: Add aws_alb_listener data source docs

Now documented.
2016-11-18 13:01:21 +02:00
Paul Stack 80e033eb16 provider/chef: Updating the provider_test comments to remove a company name (#10197) 2016-11-18 10:53:21 +02:00
Sander van Harmelen fbf27714e3 Remove the need for specifying a network ID (#10204)
When using the static NAT resource, you no longer have to specify a `network_id`. This can be inferred from the choosen `virtual_machine_id` and/or the `vm_guest_ip`.
2016-11-18 08:20:31 +01:00
Evan Brown 3920460220 Merge pull request #10081 from aditya87/google_compute_image_timeout
Added create timeout for compute images and instances
2016-11-17 12:56:02 -08:00
Paddy 642dd87f34 Merge pull request #9946 from evandbrown/google-service-account-resource
providers/google: Create and delete Service Accounts
2016-11-17 11:03:21 -08:00
Evan Brown a32fe2d47f Resolve review feedback 2016-11-17 09:49:22 -08:00
Raphael Randschau a422bf02f1 provider/scaleway: improve volume attachment (#10084)
* provider/scaleway: increase wait for server time

according to the scaleway community, shutdown/ startup might actually take an
hour. since a regular shutdown transfers data this is bound by the size of the
actual volumes in use.

https://community.online.net/t/solving-the-long-shutdown-boot-when-only-needed-to-attach-detach-a-volume/326

anyhow, 20 minutes seems quite optimistic, and we've seen some timeout errors in
the logs, too

* provider/scaleway: clear cache on volume attachment

the volume attachment errors quite often, and while I have no hard evidence
(yet) I guess it might be related to the cache that the official scaleway SDK
includes.

for now this is just a tiny experiment, clearing the cache when creating/
destroying volume attachments. let's see if this improves anything, really

* provider/scaleway: guard against attaching already attached volumes

* provider/scaleway: use cheaper instance types for tests

Scaleway bills by the hour and C2S costs much more than C1, since in the tests
we just spin up instances, to destroy them later on...
2016-11-17 15:08:05 +02:00
Chris Marchesi 99528f17cd provider/aws: Add CertificateNotFound retry waiter to aws_alb_listener (#10180)
Looks like sometimes it takes some time for IAM certificates to
propagate, which can cause errors on ALB listener creation.
Possibly same thing as hashicorp/terraform#5178, but for ALB
now instead of ELB.

This was discovered via acceptance tests, specifically the
TestAccAWSALBListener_https test. Updated the creation process to wait
on CertificateNotFound for a max of 5min.
2016-11-17 14:49:41 +02:00
Andrew Garrett 3822c69995 Add name_prefix to aws_iam_policy (#10178)
This is intended to behave the same way as name_prefix does in
aws_iam_role.

Fixes #10176
2016-11-17 14:03:03 +02:00
Clint d004a24659 Merge pull request #10171 from Ninir/vpc_enable_dns_support
provider/aws: Fixed the aws_vpc enable_dns_support handling on creation
2016-11-16 13:41:35 -06:00
Ninir 281eba72ad provider/aws: Fixed the aws_vpc enable_dns_support handling on creation 2016-11-16 20:05:49 +01:00
Paul Stack e319d2cd59 Merge pull request #10105 from hashicorp/f-chef-key_material
provider/chef: Migrate Chef to use KEY_MATERIAL rather than using a Pem file
2016-11-16 19:12:28 +02:00
stack72 50cab912af
provider/chef: Migrate Chef to use KEY_MATERIAL rather than using a Pem
file

This will allow us to standardise on how we set KEY_MATERIAL
2016-11-16 19:03:37 +02:00
Ninir 3d56d20d82 Added retry_option for aws_kinesis_firehose_stream redshift_configuration 2016-11-15 10:55:02 -06:00
Clint 665ca05bf6 Merge pull request #10112 from Ninir/aws_kinesis_firehose_stream_buffer_option
provider/aws: kinesis_firehose_delivery_stream: Fixed ES buffering_interval option
2016-11-15 09:55:12 -06:00
Justin Nauman e36f424af3 GH-7311 - Increasing deletion timeout wait
- Per our discussion around the PR to increase this initially, we
weren't sure if 1 minute would be sufficient.  Well, it turns out it
wasn't for me today (we don't delete these often so not sure how
often people run into this).

Picking another somewhat arbitrary value of 5 minutes in the hopes
that it will be sufficient (today it took a little over 2 minutes).
2016-11-15 09:11:28 -06:00
Jeremy Asher ece6f30a21 increase aws_lambda_function timeout
Since the Lambda CreateFunction call may include an up to 50MB payload,
the request can easily take more than a minute.  This increases the
timeout to 10 minutes.
2016-11-14 15:50:39 -08:00
Christoph Blecker 190f167bb2
Add support for scope aliases to google_container_cluster 2016-11-14 15:50:24 -08:00
Ninir e077e4b260 provider/aws: fixed buffering_interval option 2016-11-14 22:18:11 +01:00
Evan Brown 4bdf65c36f Fix spacing inconsistencies 2016-11-14 11:12:55 -08:00
Evan Brown 1612d6a78f Fix go vet issue 2016-11-14 09:59:44 -08:00
Evan Brown 9a188049a7 providers/google: random resource names in SA test 2016-11-14 09:42:11 -08:00
James Bardin bda84e03f7 Merge pull request #10032 from hashicorp/jbardin/vet
Fix future vet errors in providers
2016-11-14 08:49:16 -05:00
Paul Stack ecb2b74c37 Merge pull request #9534 from Ninir/aws_apigw_deployment_date
provider/aws: 	Exposed aws_api_gateway_deployment.created_date attribute
2016-11-14 12:11:59 +00:00
Paul Stack 24231333d3 Exposed AWS API GW REST Api created_date attribute (#9532) 2016-11-14 12:09:28 +00:00
Ninir a88b25cfcf Exposed AWS API GW REST Api created_date attribute 2016-11-14 11:56:41 +01:00
Ninir 6fb63f2854 Exposed aws_api_gateway_deployment.created_date attribute 2016-11-14 11:21:36 +01:00
Ninir 932c92e4c6 Exposed aws_api_gateway_api_key created_date & last_updated_date (#9530) 2016-11-14 12:03:56 +02:00
Ninir d8e846c895 Fixed ##10079 exposing aws_iam_role create_date attribute (#10091) 2016-11-14 11:33:53 +02:00
Evan Brown 5423349b68 providers/google: Create and delete Service Accounts 2016-11-13 20:47:20 -08:00
Aditya Anchuri 49c7d272a3 Added create timeout for compute images and instances
- Prevents the corresponding terraform resource from timing out when the
  images or instances take longer than the default of 4 minutes to be
  created
2016-11-12 18:30:02 -08:00
Paul Stack 3472cab7d6 provider/aws: Fix panic in aws_acm_certificate datasource (#10051)
Fixes #10042
Fixes #9989

Another panic was found with this resource. IT essentially was causing a
panic when no certificates were found. This was due to the casting of
status to []string

There are times when there are no statuses passed in. Made the error
message a lot more generic now rather than having something like this

```

No certificate with statuses [] for domain mytestdomain.com found in this region.
```

This now becomes:

```
No certificate for domain mytestdomain.com found in this region.
```

Also, added a test to show that the panic is gone

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAwsAcmCertificateDataSource_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/11 15:11:33 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAwsAcmCertificateDataSource_ -timeout 120m
=== RUN   TestAccAwsAcmCertificateDataSource_noMatchReturnsError
--- PASS: TestAccAwsAcmCertificateDataSource_noMatchReturnsError (6.07s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws6.094s
```
2016-11-11 16:07:50 +02:00
Andreas Skarmutsos Lindh 5e32c144d5
Ignore AWS specific tags
Allows us to adopt resources created with CloudFormation.

Extend AWS specific tag ignoring to all tags*

Ignore AWS specific tags for autoscaling
2016-11-11 15:40:09 +02:00
Peter McAtominey 4996f3e289 provider/azurerm: allow updating load balancer sub-resources (#10016)
* provider/azurerm: allow updating of lb_rule resource

* check if rule is being updated rather than assuming created
* added test to cover guard against multiple rules with the same name

TF_ACC=1 go test ./builtin/providers/azurerm -v -run "TestAccAzureRMLoadBalancerRule_" -timeout 120m
=== RUN   TestAccAzureRMLoadBalancerRule_basic
--- PASS: TestAccAzureRMLoadBalancerRule_basic (157.45s)
=== RUN   TestAccAzureRMLoadBalancerRule_removal
--- PASS: TestAccAzureRMLoadBalancerRule_removal (163.67s)
=== RUN   TestAccAzureRMLoadBalancerRule_inconsistentReads
--- PASS: TestAccAzureRMLoadBalancerRule_inconsistentReads (150.00s)
=== RUN   TestAccAzureRMLoadBalancerRule_update
--- PASS: TestAccAzureRMLoadBalancerRule_update (164.20s)
=== RUN   TestAccAzureRMLoadBalancerRule_duplicateRules
--- PASS: TestAccAzureRMLoadBalancerRule_duplicateRules (137.51s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	772.846s

* provider/azurerm: allow updating of lb_nat_rule resource

* check if NAT rule is being updated rather than assuming created
* added test to cover guard against multiple NAT rules with the same name

TF_ACC=1 go test ./builtin/providers/azurerm -v -run "TestAccAzureRMLoadBalancerNatRule" -timeout 120m
=== RUN   TestAccAzureRMLoadBalancerNatRule_basic
--- PASS: TestAccAzureRMLoadBalancerNatRule_basic (148.48s)
=== RUN   TestAccAzureRMLoadBalancerNatRule_removal
--- PASS: TestAccAzureRMLoadBalancerNatRule_removal (163.48s)
=== RUN   TestAccAzureRMLoadBalancerNatRule_update
--- PASS: TestAccAzureRMLoadBalancerNatRule_update (176.97s)
=== RUN   TestAccAzureRMLoadBalancerNatRule_duplicate
--- PASS: TestAccAzureRMLoadBalancerNatRule_duplicate (136.36s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	625.301s

* provider/azurerm: allow updating of lb_probe resource

* check if probe is being updated rather than assuming created
* added test to cover guard against multiple probes with the same name

TF_ACC=1 go test ./builtin/providers/azurerm -v -run "TestAccAzureRMLoadBalancerProbe" -timeout 120m
=== RUN   TestAccAzureRMLoadBalancerProbe_basic
--- PASS: TestAccAzureRMLoadBalancerProbe_basic (134.53s)
=== RUN   TestAccAzureRMLoadBalancerProbe_removal
--- PASS: TestAccAzureRMLoadBalancerProbe_removal (168.06s)
=== RUN   TestAccAzureRMLoadBalancerProbe_update
--- PASS: TestAccAzureRMLoadBalancerProbe_update (175.99s)
=== RUN   TestAccAzureRMLoadBalancerProbe_duplicate
--- PASS: TestAccAzureRMLoadBalancerProbe_duplicate (139.01s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	617.598s

* provider/azurerm: allow updating of lb_nat_pool resource

* check if NAT pool is being updated rather than assuming created
* added test to cover guard against multiple NAT pools with the same name

TF_ACC=1 go test ./builtin/providers/azurerm -v -run "TestAccAzureRMLoadBalancerNatPool" -timeout 120m
=== RUN   TestAccAzureRMLoadBalancerNatPool_basic
--- PASS: TestAccAzureRMLoadBalancerNatPool_basic (146.52s)
=== RUN   TestAccAzureRMLoadBalancerNatPool_removal
--- PASS: TestAccAzureRMLoadBalancerNatPool_removal (158.34s)
=== RUN   TestAccAzureRMLoadBalancerNatPool_update
--- PASS: TestAccAzureRMLoadBalancerNatPool_update (174.05s)
=== RUN   TestAccAzureRMLoadBalancerNatPool_duplicate
--- PASS: TestAccAzureRMLoadBalancerNatPool_duplicate (136.94s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	615.866s
2016-11-11 13:09:00 +02:00
Anshul Sharma e1919edbb3 Allow underscore in database_name [redshift] (#10019)
* allow underscore in database_name [redshift]

Fixes #10009

* Added Test Cases To Validate Redshift DBName

* Remove Old Test Cases Regarding Redshift DBName Validation

* Added More Test Cases For Redshift DBName
2016-11-11 11:59:00 +02:00
James Bardin 909099560d Fix future vet errors in providers 2016-11-10 18:10:43 -05:00
clint shryock 303b07e61f provider/aws: Update AutoScaling Schedule test files to avoid conflicts 2016-11-10 11:36:57 -06:00
stack72 e02960810d
provider/aws: Rename zone_id to hosted_zone_id in aws_db_instance
Also added a test to prove that the computed value gets set

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSDBInstance_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/10 06:26:22 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSDBInstance_basic -timeout 120m
=== RUN   TestAccAWSDBInstance_basic
--- PASS: TestAccAWSDBInstance_basic (634.33s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws634.347s
```
2016-11-10 06:41:43 +00:00
stack72 58412762eb
Merge branch 'master' of https://github.com/freeman/terraform into freeman-master 2016-11-10 06:11:47 +00:00
Mitchell Hashimoto fd498fbfff Merge pull request #9538 from hashicorp/f-nomad-provider
provider/nomad: Nomad provider for managing jobs
2016-11-09 18:34:55 -08:00
Mitchell Hashimoto f35996cd23
providers/nomad: suppress diff for identical jobspecs 2016-11-09 18:25:03 -08:00
Michel Rasschaert 62ea843ff3 zone_id exported attribute for db_instance resource 2016-11-09 19:54:09 +01:00
Mitchell Hashimoto 064691b03c Merge pull request #9997 from BedeGaming/azurerm-configure-panic
provider/azurerm: move ConfigureFunc outside of Provider literal, fixes nil reference
2016-11-09 09:56:45 -08:00
Paul Stack 643d42c412 provider/aws: AWS IAM, User and Role allow + in the name (#9991)
Fixes #9985

```
% make testacc TEST=./builtin/providers/aws
% TESTARGS='-run=TestValidateIamUserName'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/09 12:12:42 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestValidateIamUserName
-timeout 120m
=== RUN   TestValidateIamUserName
--- PASS: TestValidateIamUserName (0.00s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws0.026s
```
2016-11-09 15:54:15 +00:00
Paul Stack d66359b046 provider/aws: Fix panic when passing statuses to aws_acm_certificate (#9990)
Fixes #9989

When passing a list of statuses to the acm_certificate data source, we
were trying to cast a schema.TypeList directly to []string

We need to do it via an []interface{} and then cast to string when
ranging over the results. Without this, we get a panic
2016-11-09 15:53:36 +00:00
Peter McAtominey a23c5bda72 provider/azurerm: move ConfigureFunc outside of Provider literal, fixes nil reference
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMDnsARecord_basic -timeout 120m
=== RUN   TestAccAzureRMDnsARecord_basic
--- PASS: TestAccAzureRMDnsARecord_basic (91.92s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	91.994s
2016-11-09 15:49:14 +00:00
Nick Santamaria 8949419bef provider/aws: Add key_name_prefix argument to aws_key_pair resource (#9993)
* Added key_name_prefix to aws_key_pair resource schema.

* Added logic to prefix the aws_key_pair name on create.

* Added aws_key_pair test config for key_name_prefix case.

* Copied test cases from testAccAWSSecurityGroup namespace.

* Modified copied test case to suit aws_key_pair resource.

* Changed required flag to optional on key_name argument for aws_key_pair resource.

* Added documentation for key_name_prefix argument.

* Code style fix.

* Fixed undefined variable error in test.
2016-11-09 15:35:51 +00:00
Peter McAtominey 464fb021f7 provider/azurerm: add virtual_machine_extension resource (#9962)
Picked up from where #6548 left off

settings and protected_settings take JSON objects as strings to make extension
generic

TF_ACC=1 go test ./builtin/providers/azurerm -v -run "TestAccAzureRMVirtualMachineExtension" -timeout 120m
=== RUN   TestAccAzureRMVirtualMachineExtension_importBasic
--- PASS: TestAccAzureRMVirtualMachineExtension_importBasic (697.55s)
=== RUN   TestAccAzureRMVirtualMachineExtension_basic
--- PASS: TestAccAzureRMVirtualMachineExtension_basic (824.17s)
=== RUN   TestAccAzureRMVirtualMachineExtension_concurrent
--- PASS: TestAccAzureRMVirtualMachineExtension_concurrent (929.74s)
=== RUN   TestAccAzureRMVirtualMachineExtension_linuxDiagnostics
--- PASS: TestAccAzureRMVirtualMachineExtension_linuxDiagnostics (803.19s)
PASS
ok 	github.com/hashicorp/terraform/builtin/providers/azurerm	3254.663s
2016-11-09 15:13:48 +00:00
ddcprg 27527ef3cb EMR Cluster - core_instance_count doesn't actually refer to core instances 2016-11-09 08:47:23 -06:00
jmasseo 77ca7001a8 removing toLower from flattenElastiCacheParameters - aws_elasticache_parameter_group parameters can be case sensitive (#9820) 2016-11-09 11:34:00 +00:00
Raphael Randschau e5ff0f0cb2 provider/scaleway: update sdk (#9976)
the SDK updates includes an fix for the image cache, which might lead to wrong
images ids being returned on lookup...
2016-11-09 09:32:56 +00:00
Mitchell Hashimoto 2b7177cfe7 Merge pull request #9607 from hashicorp/f-provider-stop-redo
terraform: ResourceProvider.Stop (redo)
2016-11-08 15:58:48 -08:00
Mitchell Hashimoto 646b3c1b68 Merge pull request #9158 from hashicorp/f-vault-provider
Vault Provider
2016-11-08 15:27:33 -08:00
Raphael Randschau b0772b9131 provider/scaleway: retry volume attachment create/ destroy (#9972)
this PR fixes a flakyness in the `scaleway_volume_attachment` resource, as
described below:

when attaching/ detaching a volume from a `scaleway_server`, the server needs to
be stopped. even though the code already waits for the server to be stopped, the
`PatchServer` calls gets a `400 server is being stopped or rebooted` error
response.

If the API returns the `400` we bail, leaving terraform in a broken state.

Assuming this is the only error that the API might return to us, as the payload
itself is correct, this retry behaviour should fix the issue.

\cc @stack72 PTAL
2016-11-08 21:57:33 +00:00
Paddy 78f8fea1fa Merge pull request #9950 from optimisticanshul/9928-aws-redshift-enhanced-vpc-routing
Added AWS Redshift Enhanced VPC Routing
2016-11-08 11:02:37 -08:00
Clint 81e599e53f Merge pull request #9600 from HotelsDotCom/master
AWS EMR resource - Support for Service Access Security Group
2016-11-08 11:36:03 -06:00
Anshul Sharma e9821eaced Updated Redshift Documentation and Added Test Cases for Redshift Enchaned VPC routing 2016-11-08 18:13:10 +05:30
Anshul Sharma 1030cc1344 Added AWS Redshift Enhanced VPC Routing 2016-11-08 17:36:29 +05:30
Paddy 8ba6ed708a provider/google: throw an error for invalid disks
When configuring an instance's attached disk, if the attached disk has
both the disk and type attributes set, it would previously cause
terraform to crash with a nil pointer exception. The root cause was that
we only instantiate the InitializeParams property of the disk if its
disk attribute isn't set, and we try to write to the InitializeParams
property when the type attribute is set. So setting both caused the
InitializeParams property to not be initialized, then written to.

Now we throw an error explaining that the configuration can't have both
the disk and the type set.

Fixes #6495.
2016-11-07 16:11:00 -08:00
Paul Stack 38cd7947b6 provider/aws: Fix the validateFunc of aws_elasticache_replication_group (#9918)
Fixes #9895

The replication_group_id should allow length to be max of 20 not 16

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestResourceAWSElastiCacheReplicationGroupIdValidation'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/07 16:17:52 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestResourceAWSElastiCacheReplicationGroupIdValidation -timeout
120m
=== RUN   TestResourceAWSElastiCacheReplicationGroupIdValidation
--- PASS: TestResourceAWSElastiCacheReplicationGroupIdValidation (0.00s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws0.032s
```
2016-11-07 21:02:00 +00:00
Paul Stack c0442ee63f provider/aws: aws_alb_target_group arn_suffix missing the targetgroup (#9911)
The work to add the arn_suffix in #9734 skipped adding the targetgroup/
part of the arn

This PR adds it

//cc @firthh

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSALBTargetGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/07 12:19:16 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSALBTargetGroup_ -timeout 120m
=== RUN   TestAccAWSALBTargetGroup_basic
--- PASS: TestAccAWSALBTargetGroup_basic (47.23s)
=== RUN   TestAccAWSALBTargetGroup_changeNameForceNew
--- PASS: TestAccAWSALBTargetGroup_changeNameForceNew (80.09s)
=== RUN   TestAccAWSALBTargetGroup_changeProtocolForceNew
--- PASS: TestAccAWSALBTargetGroup_changeProtocolForceNew (87.45s)
=== RUN   TestAccAWSALBTargetGroup_changePortForceNew
--- PASS: TestAccAWSALBTargetGroup_changePortForceNew (78.47s)
=== RUN   TestAccAWSALBTargetGroup_changeVpcForceNew
--- PASS: TestAccAWSALBTargetGroup_changeVpcForceNew (73.53s)
=== RUN   TestAccAWSALBTargetGroup_tags
--- PASS: TestAccAWSALBTargetGroup_tags (75.60s)
=== RUN   TestAccAWSALBTargetGroup_updateHealthCheck
--- PASS: TestAccAWSALBTargetGroup_updateHealthCheck (76.40s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	518.777s
```
2016-11-07 20:17:43 +00:00
Paul Stack 3f032ff611 provider/aws: Setting static_routes_only on import of vpn_connection (#9802)
fixes #9110

An error was found where, static_routes_only was not set on a vpn
connection import. This commit introduces setting the static_routes_only
to false when no Options are found. This follows the AWS convention as follows:

```
- options (structure)

Indicates whether the VPN connection requires static routes. If you are creating a VPN connection for a device that does not support BGP, you must specify true .
Default: false

```

So we take it that `static_options_only` is false by default

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSVpnConnection_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/02 10:38:18 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSVpnConnection_ -timeout 120m
=== RUN   TestAccAWSVpnConnection_importBasic
--- PASS: TestAccAWSVpnConnection_importBasic (178.29s)
=== RUN   TestAccAWSVpnConnection_basic
--- PASS: TestAccAWSVpnConnection_basic (336.81s)
=== RUN   TestAccAWSVpnConnection_withoutStaticRoutes
--- PASS: TestAccAWSVpnConnection_withoutStaticRoutes (195.45s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	710.572s
```
2016-11-07 16:12:41 +00:00
Masayuki Morita f68d5e82f3 provider/aws: Fix bug #9863 destroying aws_iam_user with force_destroy does not work (#9900) 2016-11-07 10:37:32 +00:00
Tom Harvey b15b7e1c40 provider/azurerm: EventHubs (#9889)
* Implemented EventHubs

* Missing the sidebar link

* Fixing the type

* Fixing the docs for Namespace

* Removing premium tests

* Checking the correct status code on delete

* Added a test case for the import

* Documentation for importing

* Fixing a typo
2016-11-07 10:19:59 +00:00
James Nugent a0c5d42fa4 provider/random: Separate read from create
We now generate the read operation which sets the various encodings of
the random value such that adding new ones does not require generating a
new random value.

We also verify that these are set correctly via the acceptance tests.
2016-11-06 17:05:11 -06:00
James Nugent 65a8c7bb3f Merge pull request #9903 from hashicorp/random-std-b64-encoding
provider/random: Add b64_std to random_id
2016-11-06 16:25:08 -06:00
James Nugent 9f4e1ec5eb Merge pull request #9865 from sthulb/remove-dep-mime/multipart
Remove sthulb/mime/multipart
2016-11-06 10:24:45 -06:00
James Nugent a7451bfab3 provider/random: Use schema Noop functions 2016-11-06 10:07:38 -06:00
James Nugent 314a56e503 provider/random: Add b64_std to random_id
This commit makes three related changes to the `random_id` resource:

1. Deprecate the `b64` attribute
2. Introduce a new `b64_url` attribute which functions in the same
   manner as the original `b64` attribute
3. Introduce a new `b64_std` attribute which uses standard base64
   encoding for the value rather than URL encoding.

Resource identifiers continue to use URL encoded base 64.

The reason for adding standard encoding of the base 64 value is to allow
the use of generated values as a Serf Encryption Key for separating
Consul clusters - these rely on standard encoding and do not permit some
characters which are allowed by URL encoding. `b64_url` is introduced
in order that there is consistency in specifying the desired encoding
during interpolation.
2016-11-06 09:58:24 -06:00
Joe Topjian 6f67b693c0 Merge pull request #9836 from fatmcgav/openstack_fw_firewall_v1_add_value_specs
provider/openstack: Add 'value_specs' option to 'openstack_fw_firewall_v1' resource
2016-11-05 09:04:04 -06:00
Raphael Randschau fc0455f63a provider/scaleway: fix `scaleway_image` datasource returning unknown images (#9899)
* provider/scaleway: expose scaleway_image lookup error

* provider/scaleway: fix image lookup error

fixes #9472
2016-11-05 11:37:02 +00:00
Gavin Williams b0981566ec provider/openstack: Add 'value_specs' option to 'openstack_fw_firewall_v1' resource
Refactor to use common 'types.go' and 'MapValueSpecs' function.
Website docs updated to reflect changes.
2016-11-05 10:17:33 +00:00
Gavin Williams d3b2c15a2c provider/openstack: Add 'value_specs' option to 'openstack_fw_policy_v1' resource
Refactor to use common 'types.go' and 'MapValueSpecs' function.
Website docs updated to reflect additions
2016-11-04 19:06:25 +00:00
Paddy a15726d069 Merge pull request #9857 from hashicorp/paddy_8822_fix_spot_fleet_ebs
provider/aws: Fix hashing of EBS volumes in spot fleet requests to prevent panics
2016-11-04 09:38:38 -07:00
Mitchell Hashimoto 125b7f4d44 Merge pull request #9806 from hashicorp/f-modify-aws-user-agent
provider/aws: Modify AWS User-Agent to new format
2016-11-04 08:50:15 -07:00
Joe Topjian c3d6bdd440 Merge pull request #9834 from fatmcgav/openstack_firewall_rule_v1_add_value_specs
provider/openstack: Add 'value_specs' option to 'openstack_fw_rule_v1' resource
2016-11-04 09:14:19 -06:00
Clint abcc766344 Merge pull request #9871 from hashicorp/b-aws-opsworks-tests
provider/aws: Decouple and randomize OpsWorks test configs
2016-11-04 09:40:48 -05:00
clint shryock 639a088897 provider/aws: Decouple and randomize OpsWorks test configs 2016-11-04 09:33:07 -05:00
James Nugent c75369d65d Merge pull request #8359 from hashicorp/f-aws-acm-datasource
provider/aws: New Data Source: aws_acm_certificate
2016-11-04 07:49:58 -04:00
Simon Thulbourn 1ca1f86713 Remove sthulb/mine/multipart
This dep was meant as a stopgap for a patch in the stdlib of Go which I
wrote.

The patch was released in Go 1.7. We can now remove my fork and go back
to the stdlib
2016-11-04 11:23:21 +00:00
Gavin Williams e3246bc63e provider/openstack: Add 'value_specs' option to 'openstack_fw_rule_v1' resource.
Refactor to use common 'types.go' and 'MapValueSpecs' function.
Website docs updated.
2016-11-04 07:19:50 +00:00
Joe Topjian 41adcb8388 Merge pull request #9832 from fatmcgav/openstack_fw_firewall_v1_admin_state_up_default
provider/openstack: resource_openstack_fw_firewall_v1 'admin_state_up' should default to 'true'
2016-11-03 19:35:10 -06:00
James Nugent 3361047e38 provider/aws: Address acm_certificate review items 2016-11-03 20:01:46 -04:00
Paul Hinze ccd745c96f provider/aws: New Data Source: aws_acm_certificate
Use this data source to get the ARN of a certificate in AWS Certificate
Manager (ACM). The process of requesting and verifying a certificate in ACM
requires some manual steps, which means that Terraform cannot automate the
creation of ACM certificates. But using this data source, you can reference
them by domain without having to hard code the ARNs as input.

The acceptance test included requires an ACM certificate be pre-created
in and information about it passed in via environment variables. It's a
bit sad but there's really no other way to do it.
2016-11-03 19:34:19 -04:00
Paddy 7d06ea8449 Fix EBS block device hashing in spot fleet requests.
When computing the set key for an EBS block device, we were using
the wrong function; we had hashEphemeralBlockDevice instead of
hashEbsBlockDevice. This caused a panic by trying to access the
virtual_name attribute that will never be set for EBS block
devices.

To fix this, I switched to the hashEbsBlockDevice function, which
is already being used to compute a Set key in the Schema. But in
the default case, where the snapshot_id attribute isn't specified,
this also caused a panic. I updated the way the string to hash is
generated to check for the existence of the device_name and
snapshot_id attributes before we use them, to avoid panics when
these optional attributes aren't set.
2016-11-03 16:24:19 -07:00
Paddy 24dd4273c7 Add an acceptance test for adding EBS volumes to a spot fleet req
Spot fleet requests can have EBS volumes attached to them, and at
the moment we're getting reports that crashes can be experienced
with them. This adds an acceptance test that exercises creating
a Spot Fleet request that has a non-instance EBS volume attached.
This successfully reproduces the panic.
2016-11-03 16:19:50 -07:00
Joe Topjian a8c750d4f7 Merge pull request #9830 from fatmcgav/openstack_fw_policy_shared_fix
provider/openstack: Don't default 'shared' value, instead only set if…
2016-11-03 09:08:52 -06:00
Justin Nauman 9e11b59814 provider/aws: aws_autoscaling_attachment resource (#9146)
* GH-8755 - Adding in support to attach ASG to ELB as independent action

* GH-8755 - Adding in docs

* GH-8755 - Adjusting attribute name and responding to other PR feedback
2016-11-03 13:08:49 +00:00
Gavin Williams ea9cc43578 provider/openstack: resource_openstack_fw_firewall_v1 'admin_state_up' should default to 'true' 2016-11-03 12:15:04 +00:00
stack72 f5cd90c13e
provider/postgresql: Fixing up the PG Extension test 2016-11-03 12:06:51 +00:00
stack72 16ce2c2e9c
Merge branch 'postgresql-extensions' of https://github.com/samdunne/terraform into samdunne-postgresql-extensions 2016-11-03 12:05:25 +00:00
Gavin Williams 53eea2121e provider/openstack: Don't default 'shared' value, instead only set if specified.
Documentation updated to reflect removal of default value.
Fixes #9829
2016-11-03 11:21:39 +00:00
James Nugent 549993147f Merge pull request #9822 from hashicorp/paddy_8502_sni
provider/aws: Add the enable_sni attribute for Route53 health checks.
2016-11-02 23:38:01 -04:00
Paddy 42049e984f provider/aws: Add the enable_sni attribute for Route53 health checks.
In #8502 it was requested that we add support for the EnableSNI
parameter of Route53's health checks; this enables customers to
manually specify whether or not the health check will use SNI when
communicating with the endpoint.

The customer originally requested we default to `false`. While
implementing the issue, I discovered that when creating health
checks with a Type set to HTTP, Amazon's default value for EnableSNI
is `false`. However, when creating health checks with a Type set to
HTTPS, Amazon's default value is `true`. So rather than setting a
default value, I made the attribute computed.
2016-11-02 16:23:35 -07:00
Peter McAtominey 491a74fd53 provider/azurerm: allow storage_account resource with name "$root" (#9813)
Fixes #8763

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMStorageContainer -timeout 120m
=== RUN   TestAccAzureRMStorageContainer_basic
--- PASS: TestAccAzureRMStorageContainer_basic (131.40s)
=== RUN   TestAccAzureRMStorageContainer_disappears
--- PASS: TestAccAzureRMStorageContainer_disappears (126.20s)
=== RUN   TestAccAzureRMStorageContainer_root
--- PASS: TestAccAzureRMStorageContainer_root (125.98s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	383.661s
2016-11-02 22:57:57 +00:00
clint shryock d120e1a38a provider/aws: Fix TestAccAWSAPIGatewayDomainName_basic test 2016-11-02 16:23:39 -05:00
Paul Stack c5bd727f03 provider/aws: Allows aws_alb security_groups to be updated (#9804)
Fixes #9658
Fixes #8728

Originally, this would ForceNew as follows:

```
-/+ aws_alb.alb_test
    arn:                        "arn:aws:elasticloadbalancing:us-west-2:187416307283:loadbalancer/app/test-alb-9658/3459cd2446b76901" => "<computed>"
    arn_suffix:                 "app/test-alb-9658/3459cd2446b76901" => "<computed>"
    dns_name:                   "test-alb-9658-1463108301.us-west-2.elb.amazonaws.com" => "<computed>"
    enable_deletion_protection: "false" => "false"
    idle_timeout:               "30" => "30"
    internal:                   "false" => "false"
    name:                       "test-alb-9658" => "test-alb-9658"
    security_groups.#:          "2" => "1" (forces new resource)
    security_groups.1631253634: "sg-3256274b" => "" (forces new resource)
    security_groups.3505955000: "sg-1e572667" => "sg-1e572667" (forces new resource)
    subnets.#:                  "2" => "2"
    subnets.2407170741:         "subnet-ee536498" => "subnet-ee536498"
    subnets.2414619308:         "subnet-f1a7b595" => "subnet-f1a7b595"
    tags.%:                     "1" => "1"
    tags.TestName:              "TestAccAWSALB_basic" => "TestAccAWSALB_basic"
    vpc_id:                     "vpc-dd0ff9ba" => "<computed>"
    zone_id:                    "Z1H1FL5HABSF5" => "<computed>"

Plan: 1 to add, 0 to change, 1 to destroy.
```

When the ALB was ForceNew, the ARN changed. The test has been updated to include a check to make sure that the ARNs are the same after the update

After this change, it looks as follows:

```
~ aws_alb.alb_test
    security_groups.#:          "1" => "2"
    security_groups.1631253634: "" => "sg-3256274b"
    security_groups.3505955000: "sg-1e572667" => "sg-1e572667"

Plan: 0 to add, 1 to change, 0 to destroy.
```

Test Results:

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSALB_'                                                                                                                                ✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/02 12:20:58 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSALB_ -timeout 120m
=== RUN   TestAccAWSALB_basic
--- PASS: TestAccAWSALB_basic (64.25s)
=== RUN   TestAccAWSALB_generatedName
--- PASS: TestAccAWSALB_generatedName (65.04s)
=== RUN   TestAccAWSALB_namePrefix
--- PASS: TestAccAWSALB_namePrefix (67.02s)
=== RUN   TestAccAWSALB_tags
--- PASS: TestAccAWSALB_tags (96.06s)
=== RUN   TestAccAWSALB_updatedSecurityGroups
--- PASS: TestAccAWSALB_updatedSecurityGroups (101.61s)
=== RUN   TestAccAWSALB_noSecurityGroup
--- PASS: TestAccAWSALB_noSecurityGroup (59.83s)
=== RUN   TestAccAWSALB_accesslogs
--- PASS: TestAccAWSALB_accesslogs (162.65s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	616.489s
```
2016-11-02 16:11:12 +00:00
clint shryock 5cd40bce30 provider/aws: Modify AWS User-Agent to new format 2016-11-02 10:43:35 -05:00
Sam Dunne cb40a3ef14
Format code 2016-11-02 15:30:21 +00:00
Paul Stack 6649b938da provider/aws: Provide the option to skip_destroy on aws_volume_attachment (#9792)
* provider/aws: Provide the option to skip_destroy on
aws_volume_attachment

When you want to attach and detach pre-existing EBS volumes to an
instance, we would do that as follows:

```
resource "aws_instance" "web" {
	ami = "ami-21f78e11"
  availability_zone = "us-west-2a"
	instance_type = "t1.micro"
	tags {
		Name = "HelloWorld"
	}
}

data "aws_ebs_volume" "ebs_volume" {
  filter {
  	name = "size"
  	values = ["${aws_ebs_volume.example.size}"]
  }
  filter {
  	name = "availability-zone"
  	values = ["${aws_ebs_volume.example.availability_zone}"]
  }
  filter {
  	name = "tag:Name"
  	values = ["TestVolume"]
  }
}

resource "aws_volume_attachment" "ebs_att" {
  device_name = "/dev/sdh"
	volume_id = "${data.aws_ebs_volume.ebs_volume.id}"
	instance_id = "${aws_instance.web.id}"
	skip_destroy = true
}
```

The issue here is that when we run a terraform destroy command, the volume tries to get detached from a running instance and goes into a non-responsive state. We would have to force_destroy the volume at that point and risk losing any data on it.

This PR introduces the idea of `skip_destroy` on a volume attachment. tl;dr:

We want the volume to be detached from the instane when the instance itself has been destroyed. This way the normal shut procedures will happen and protect the disk for attachment to another instance

Volume Attachment Tests:

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSVolumeAttachment_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/02 00:47:27 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSVolumeAttachment_ -timeout 120m
=== RUN   TestAccAWSVolumeAttachment_basic
--- PASS: TestAccAWSVolumeAttachment_basic (133.49s)
=== RUN   TestAccAWSVolumeAttachment_skipDestroy
--- PASS: TestAccAWSVolumeAttachment_skipDestroy (119.64s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	253.158s
```

EBS Volume Tests:

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEBSVolume_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/02 01:00:18 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEBSVolume_ -timeout 120m
=== RUN   TestAccAWSEBSVolume_importBasic
--- PASS: TestAccAWSEBSVolume_importBasic (26.38s)
=== RUN   TestAccAWSEBSVolume_basic
--- PASS: TestAccAWSEBSVolume_basic (26.86s)
=== RUN   TestAccAWSEBSVolume_NoIops
--- PASS: TestAccAWSEBSVolume_NoIops (27.89s)
=== RUN   TestAccAWSEBSVolume_withTags
--- PASS: TestAccAWSEBSVolume_withTags (26.88s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	108.032s
```

* Update volume_attachment.html.markdown
2016-11-02 15:29:37 +00:00
Sam Dunne 5dbd9423cc
Update based off review 2016-11-02 14:36:39 +00:00
Christoph Blecker af7cd57a4a Search configured project image families (#9243)
* Search configured project image families

* Clarify documentation around google_compute_instance image families

* Acceptance test for private instance family creation
2016-11-01 21:00:12 +00:00
Peter McAtominey 565e8719db provider/azurerm: update Azure SDK to 6.0 Beta (#9700)
Fix keyvault KeyPermissions references
2016-11-01 19:25:20 +00:00
Martin Atkins 145bf42806 provider/aws: IAM policy document: normalize wildcard principals
There are three equivalent forms for expressing "everyone" (including
anonymous) in IAM policies:

- "Principals": "*"
- "Principals": {"AWS": "*"}
- "Principals": {"*": "*"}

The more-constrained syntax used by our aws_iam_policy_document data
source means that the user can only express the latter two of these
directly. However, when returning IAM policies from the API AWS likes to
normalize to the first form, causing unresolvable diffs.

This fixes #9335 by handling the "everyone" case as a special case,
serializing it in JSON as the "*" shorthand form.

This change does *not* address the normalization of hand-written policies
containing such elements. A similar change would need to be made in
the external package github.com/jen20/awspolicyequivalence in order to
avoid the issue for hand-written policies.
2016-11-01 08:46:34 -07:00
Paul Stack aaece37ec9 provider/aws: Adding a datasource for aws_ebs_volume (#9753)
This will allows us to filter a specific ebs_volume for attachment to an
aws_instance

```
make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEbsVolumeDataSource_'✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/01 12:39:19 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSEbsVolumeDataSource_ -timeout 120m
=== RUN   TestAccAWSEbsVolumeDataSource_basic
--- PASS: TestAccAWSEbsVolumeDataSource_basic (28.74s)
=== RUN   TestAccAWSEbsVolumeDataSource_multipleFilters
--- PASS: TestAccAWSEbsVolumeDataSource_multipleFilters (28.37s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws57.145s
```
2016-11-01 14:15:31 +00:00
Christoph Blecker 45f441fdb4 Add support for default-internet-gateway alias for google_compute_route (#9676) 2016-11-01 13:45:36 +00:00
Joe Topjian 266b5ab598 provider/openstack: Openstack Provider Updates (#9725)
* provider/openstack: Adding Identity v3 compatible environment variables

* provider/openstack: Adding missing environment variables

* provider/openstack: line spacing for provider options

* provider/openstack: Making password sensitive

* provider/openstack: Adding descriptions to provider options

* provider/openstack: Clean up provider documentation

* provider/openstack: clean up EndpointType check
2016-11-01 13:16:39 +00:00
Peter McAtominey f2606bfa5d provider/azurerm: fix sql_database resource reading tags (#9767)
tags were not being set in the read function

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMSqlDatabase_basic -timeout 120m
=== RUN   TestAccAzureRMSqlDatabase_basic
--- PASS: TestAccAzureRMSqlDatabase_basic (190.60s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	190.719s
2016-11-01 10:55:02 +00:00
Christoph Blecker ca8cd4b1f0 Add support for using source_disk to google_compute_image (#9614) 2016-11-01 10:32:47 +00:00
Joe Topjian b269b417b0 provider/openstack: LoadBalancer v2 VIP Port ID (#9727)
This commit adds vip_port_id as an exported attribute to the
lb_loadbalancer_v2 resource.
2016-11-01 10:25:18 +00:00
Krzysztof Wilczynski 6f02a2df55 provider/aws: Allow `active` state while waiting for the VPC Peering Connection. (#9754)
* Allow `active` state while waiting for the VPC Peering Connection.

This commit adds `active` as one of the valid states in which the VPC Peering
Connection can be when it being created.

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

* Add more valid states.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-11-01 09:51:46 +00:00
Paul Stack 98c385723c provider/aws: Fix aws_route53_record alias perpetual diff (#9704)
Fixes #9628
Fixes #9298

When a route53_record alias is updated in the console, AWS prepends
`dualstack.` to the name. This is there incase IPV6 is wanted. It is
exactly the same without it as it is with it

In order to stop perpetual diffs, I introduced a normalizeFunc that will
that tke alias name and strip known issues:

* dualstack
* trailing dot

This normalize fun will continue to grow I'm sure

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSRoute53Record_'                                         ✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/29 00:28:12 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSRoute53Record_ -timeout 120m
=== RUN   TestAccAWSRoute53Record_basic
--- PASS: TestAccAWSRoute53Record_basic (124.64s)
=== RUN   TestAccAWSRoute53Record_basic_fqdn
--- PASS: TestAccAWSRoute53Record_basic_fqdn (132.07s)
=== RUN   TestAccAWSRoute53Record_txtSupport
--- PASS: TestAccAWSRoute53Record_txtSupport (134.07s)
=== RUN   TestAccAWSRoute53Record_spfSupport
--- PASS: TestAccAWSRoute53Record_spfSupport (113.36s)
=== RUN   TestAccAWSRoute53Record_generatesSuffix
--- PASS: TestAccAWSRoute53Record_generatesSuffix (112.62s)
=== RUN   TestAccAWSRoute53Record_wildcard
--- PASS: TestAccAWSRoute53Record_wildcard (162.84s)
=== RUN   TestAccAWSRoute53Record_failover
--- PASS: TestAccAWSRoute53Record_failover (126.18s)
=== RUN   TestAccAWSRoute53Record_weighted_basic
--- PASS: TestAccAWSRoute53Record_weighted_basic (121.10s)
=== RUN   TestAccAWSRoute53Record_alias
--- PASS: TestAccAWSRoute53Record_alias (118.14s)
=== RUN   TestAccAWSRoute53Record_s3_alias
--- PASS: TestAccAWSRoute53Record_s3_alias (155.07s)
=== RUN   TestAccAWSRoute53Record_weighted_alias
--- PASS: TestAccAWSRoute53Record_weighted_alias (235.41s)
=== RUN   TestAccAWSRoute53Record_geolocation_basic
^[[C--- PASS: TestAccAWSRoute53Record_geolocation_basic (125.32s)
=== RUN   TestAccAWSRoute53Record_latency_basic
--- PASS: TestAccAWSRoute53Record_latency_basic (122.23s)
=== RUN   TestAccAWSRoute53Record_TypeChange
--- PASS: TestAccAWSRoute53Record_TypeChange (231.98s)
=== RUN   TestAccAWSRoute53Record_empty
--- PASS: TestAccAWSRoute53Record_empty (116.48s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	2131.526s
```

Before this fix, I was getting the following by recreating the code in

```
~ aws_route53_record.alias
    alias.1563903989.evaluate_target_health: "true" => "false"
    alias.1563903989.name:                   "9828-recreation-106795730.us-west-2.elb.amazonaws.com." => ""
    alias.1563903989.zone_id:                "Z1H1FL5HABSF5" => ""
    alias.318754017.evaluate_target_health:  "" => "true"
    alias.318754017.name:                    "" => "9828-recreation-106795730.us-west-2.elb.amazonaws.com"
    alias.318754017.zone_id:                 "" => "Z1H1FL5HABSF5"

Plan: 0 to add, 1 to change, 0 to destroy.
```

After this fix:

```

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-10-31 19:18:00 +00:00
Anshul Sharma 6432bb546c Added AWS Resource WAF SqlInjectionMatchSet (#9709) 2016-10-31 17:51:47 +00:00
Paul Stack fdabf59380 provider/aws: Expose ARN suffix on ALB Target Group (#9734)
When creating a CloudWatch Metric for an Application Load Balancer Target Group  it is
neccessary to use the suffix of the ARN as the reference to the load
balancer TG . This commit exposes that as an attribute on the `aws_alb_target_group`
resource to prevent the need to use regular expression substitution to
make the reference.
2016-10-31 17:05:06 +00:00
Paul Stack 7ddc7211ca provider/azurerm: Guard against panic when importing arm_virtual_network (#9739)
Fixes #9410

When importing an azurerm_virtual_network that has no DNSServers,
terraform was throwing a panic as it was trying to dereference that list
of servers to set to state

This commit adds a simple check to make sure there are DNSServers before
dereferencing them

```
make testacc TEST=./builtin/providers/azurerm TESTARGS='-run=TestAccAzureRMVirtualNetwork_'                            2 ↵ ✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/31 11:20:36 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/azurerm -v
-run=TestAccAzureRMVirtualNetwork_ -timeout 120m
=== RUN   TestAccAzureRMVirtualNetwork_importBasic
--- PASS: TestAccAzureRMVirtualNetwork_importBasic (150.63s)
=== RUN   TestAccAzureRMVirtualNetwork_basic
--- PASS: TestAccAzureRMVirtualNetwork_basic (122.90s)
=== RUN   TestAccAzureRMVirtualNetwork_disappears
--- PASS: TestAccAzureRMVirtualNetwork_disappears (113.07s)
=== RUN   TestAccAzureRMVirtualNetwork_withTags
--- PASS: TestAccAzureRMVirtualNetwork_withTags (139.56s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/azurerm526.168
```
2016-10-31 17:03:12 +00:00
Paul Stack ed49da8bb1 provider/aws: Add support for reference_name to aws_route53_health_check (#9737)
Fixes #8679

The CallerReference attribute we passed to AWS in route53_health_checks
was `time.Now().Format(time.RFC3339Nano)`

When creating multiple resources with the Count meta-parameter, this was
causing issues as follows:

```
* aws_route53_health_check.healthstate.0: HealthCheckAlreadyExists: A different health check has already been created with the specified caller reference.
```

We have now exposed a new attribute called `reference_name` that can be set to pass multiple resources to the request

```
make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSRoute53HealthCheck_'                              130 ↵ ✹
==> Cecking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/31 10:41:07 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSRoute53HealthCheck_ -timeout 120m
=== RUN   TestAccAWSRoute53HealthCheck_importBasic
--- PASS: TestAccAWSRoute53HealthCheck_importBasic (17.08s)
=== RUN   TestAccAWSRoute53HealthCheck_basic
--- PASS: TestAccAWSRoute53HealthCheck_basic (28.17s)
=== RUN   TestAccAWSRoute53HealthCheck_withSearchString
--- PASS: TestAccAWSRoute53HealthCheck_withSearchString (28.07s)
=== RUN   TestAccAWSRoute53HealthCheck_withChildHealthChecks
--- PASS: TestAccAWSRoute53HealthCheck_withChildHealthChecks (20.71s)
=== RUN   TestAccAWSRoute53HealthCheck_IpConfig
--- PASS: TestAccAWSRoute53HealthCheck_IpConfig (16.09s)
=== RUN   TestAccAWSRoute53HealthCheck_CloudWatchAlarmCheck
--- PASS: TestAccAWSRoute53HealthCheck_CloudWatchAlarmCheck (22.42s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	132.568s
```
2016-10-31 16:00:40 +00:00
Clint f446f7f2be Merge pull request #9667 from hashicorp/b-aws-lambda-mutex
provider/aws: Limit AWS Lambda source uploads
2016-10-31 08:51:08 -05:00
Paul Stack 92f48ad243 provider/aws: Update aws_appautoscaling_target_test (#9736)
The update of the test was causing a test failure - it was setting
desired_count to 1 when miz_size was set to 2 - this was causing a
perpetual diff in the test
2016-10-31 10:40:35 +00:00
Paul Stack 3accd5485a provider/aws: Make iam_user_policy_attachment_test work as expected: (#9733)
Was failing due to using IAM user `test-name` as it was being used in
more than 1 place - this has been replaced by a random user and random
policy names now

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSUserPolicyAttachment_basic'                                                                               2 ↵ ✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/31 08:39:08 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSUserPolicyAttachment_basic -timeout 120m
=== RUN   TestAccAWSUserPolicyAttachment_basic
--- PASS: TestAccAWSUserPolicyAttachment_basic (32.04s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	32.053s
```
2016-10-31 09:52:38 +00:00
Martin Atkins ea0bc04277 provider/aws: aws_ami: handle deletion of AMIs (#9721)
Previously this resource (and, by extension, the aws_ami_copy and
aws_ami_from_instance resources that share much of its implementation)
was handling correctly the case where an AMI had been recently
deregistered, and was thus still returned from the API, but not correctly
dealing with the situation where the AMI has been removed altogether.

Now we additionally handle the NotFound error returned by the API when
we request a non-existent AMI, and remove the AMI from the state in the
same way we do for deregistered AMIs.
2016-10-31 09:51:59 +00:00
Anshul Sharma 625e747359 Added AWS Resource WAF XssMatchSet (#9710) 2016-10-31 08:51:08 +00:00
Martin Atkins 25f73dac83 provider/vault: vault_generic_secret data source 2016-10-29 23:16:57 -07:00
Martin Atkins c1d1f902f5 provider/vault: vault_generic_secret resource
This resource allows writing a generic secret, and indeed anything else
that obeys the expected create/update/delete lifecycle, into vault via
writes to its logical path namespace.
2016-10-29 23:16:57 -07:00
Martin Atkins b2b5831205 "vault" provider registration
To reduce the risk of secret exposure via Terraform state and log output,
we default to creating a relatively-short-lived token (20 minutes) such
that Vault can, where possible, automatically revoke any retrieved
secrets shortly after Terraform has finished running.

This has some implications for usage of this provider that will be spelled
out in more detail in the docs that will be added in a later commit, but
the most significant implication is that a plan created by "terraform plan"
that includes secrets leased from Vault must be *applied* before the
lease period expires to ensure that the issued secrets remain valid.

No resources yet. They will follow in subsequent commits.
2016-10-29 23:16:57 -07:00
Masayuki Morita eb1a58d966 Update doc: aws_iam_user with force_destroy deletes IAM User Login Profile (#9716)
refs: https://github.com/hashicorp/terraform/pull/9583
2016-10-29 16:20:18 +01:00
Raphael Randschau 98d84680b7 provider/scaleway server volume property (#9695)
* provider/scaleway: extract volume validation helpers

* provider/scaleway: add server volume property

fixes #9499

* provider/scaleway: update `scaleway_server` docu

* provider/scaleway: fix volume handling

this actually broken when merging the latest SDK update :(

* provider/scaleway: fix volume attachment

* provider/scaleway: fix volume expectation
2016-10-29 12:07:35 +01:00
Clint 01e8bd1f70 provider/aws: Fix import of RouteTable with destination prefixes (#9686)
* add test failure

* provider/aws: Skip import of routes that contain destination prefix ids
2016-10-29 01:01:17 +02:00
Anshul Sharma cc8f11138f Added AWS Resource WAF SizeConstraintSet (#9689) 2016-10-29 00:58:37 +02:00
Raphael Randschau 082ef04b9e provider/scaleway: update sdk for ams1 region (#9687)
* provider/scalway: update sdk for ams1 region

* provider/scaleway typecast volume size as of 472a493
2016-10-29 00:16:53 +02:00
Dan Wendorf 781725348e provider/google Support MySQL 5.7 instances (#9673)
* provider/google Document MySQL versions for second generation instances

Google Cloud SQL has first-gen and second-gen instances with different
supported versions of MySQL.

* provider/google Increase SQL Admin operation timeout to 10 minutes

Creating SQL instances for MySQL 5.7 can take over 7 minutes,
so the timeout needs to be increased to allow the
google_sql_database_instance resource to successfully create.
2016-10-28 14:41:03 +02:00
Andras Ferencz-Szabo 46cb7b4710 Allow underscores in IAM user and group names (#9684)
* Allow underscores in IAM user and group names

* Add notes to iam_user and iam_group docs that names are not distinguished by case
2016-10-28 14:40:04 +02:00
Anshul Sharma afc603c0f8 Added AWS Resource WAF ByteMatchSet (#9681) 2016-10-28 14:36:16 +02:00
Liam Bennett 8fee7642a9 New AWS resource `ssm_activation` (#9111)
Adding a new resource to support activation of managed instances for
on-premise virtual-machines.
2016-10-28 11:59:12 +02:00
Dan Wendorf 407af92c21 provider/google Change default MySQL instance version to 5.6 (#9674)
The Google Cloud SQL API defaults to 5.6, and 5.6 is the only version avaiable
to both first- and second-generation Cloud SQL instances.
2016-10-28 00:11:08 +01:00
Krzysztof Wilczynski a078b893d6 Add support for `AutoMinorVersionUpgrade` to aws_elasticache_replication_group resource. (#9657)
This commit adds an ability to modify the `AutoMinorVersionUpgrade` property of the
Replication Group (which is enabled by default) accordingly.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-28 00:08:14 +01:00
clint shryock b33d605cb0 provider/aws: Limit AWS Lambda source uploads 2016-10-27 14:41:20 -05:00
ddegoede 2531ab024a Adding private gateway and static route resource to cloudstack provider (#9637)
* Adding private gateway and static route resource to cloudstack provider

Testing the private gateway and static route resource requires a ROOT
account in Cloudstack

* changes requested by reviewer
2016-10-27 21:06:39 +02:00
Dana Hoffman ab01c23140 style fix 2016-10-27 11:25:28 -07:00
Paul Stack de6b51f8f9 provider/aws: Refresh aws_autoscaling_schedule from state on 404 (#9659)
Fixes #9654

Before the fix, I created an ASG with a schedule on it. Went to the AWS
console and deleted the schedule. A terraform plan looked as follows:

```
% terraform plan
    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.foobar: Refreshing state... (ID:
    terraform-test-foobar5)
    aws_autoscaling_group.foobar: Refreshing state... (ID:
    terraform-test-foobar5)
    aws_autoscaling_schedule.foobar: Refreshing state... (ID: foobar)
    Error refreshing state: 1 error(s) occurred:

    * aws_autoscaling_schedule.foobar: Unable to find Autoscaling
    * Scheduled Action: []*autoscaling.ScheduledUpdateGroupAction(nil)
```

After the fix:

```
terraform plan                                                                                                                           1 ↵
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.foobar: Refreshing state... (ID: terraform-test-foobar5)
aws_autoscaling_group.foobar: Refreshing state... (ID: terraform-test-foobar5)
aws_autoscaling_schedule.foobar: Refreshing state... (ID: foobar)

The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed. Cyan entries are data sources to be read.

Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.

+ aws_autoscaling_schedule.foobar
    arn:                    "<computed>"
    autoscaling_group_name: "terraform-test-foobar5"
    desired_capacity:       "0"
    end_time:               "2018-01-16T13:00:00Z"
    max_size:               "0"
    min_size:               "0"
    recurrence:             "<computed>"
    scheduled_action_name:  "foobar"
    start_time:             "2018-01-16T07:00:00Z"

Plan: 1 to add, 0 to change, 0 to destroy.
```

Tests run as expected:

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAutoscalingSchedule_'                                               2 ↵ ✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/27 17:45:19 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAutoscalingSchedule_ -timeout 120m
=== RUN   TestAccAWSAutoscalingSchedule_basic
--- PASS: TestAccAWSAutoscalingSchedule_basic (140.94s)
=== RUN   TestAccAWSAutoscalingSchedule_disappears
--- PASS: TestAccAWSAutoscalingSchedule_disappears (179.17s)
=== RUN   TestAccAWSAutoscalingSchedule_recurrence
--- PASS: TestAccAWSAutoscalingSchedule_recurrence (186.72s)
=== RUN   TestAccAWSAutoscalingSchedule_zeroValues
--- PASS: TestAccAWSAutoscalingSchedule_zeroValues (167.73s)
PASS
ok	github.com/hashicorp/terraform/builtin/providers/aws	674.530s
```
2016-10-27 18:39:15 +01:00
Mathieu Herbert 7f9baf7009 provider/aws: data source for AWS Security Group (#9604)
* provider/aws: data source for AWS Security Group

* provider/aws: add documentation  for data source for AWS Security Group

* provider/aws: data source for AWS Security Group (improve if condition and syntax)

* fix fmt
2016-10-27 18:17:58 +01:00
Raphael Randschau d9a2e0dbb3 provider/scaleway: fix scaleway_volume_attachment with count > 1 (#9493)
* provider/scaleway: fix scaleway_volume_attachment with count > 1

since scaleway requires servers to be powered off to attach volumes to, we need
to make sure that we don't power down a server twice, or power up a server while
it's supposed to be modified.

sadly terraform doesn't seem to sport serialization primitives for usecases like
this, but putting the code in question behind a `sync.Mutex` does the trick, too

fixes #9417

* provider/scaleway: use mutexkv to lock per-resource

following  @dcharbonnier  suggestion. thanks!

* provider/scaleway: cleanup waitForServerState signature

* provider/scaleway: store serverID in var

* provider/scaleway: correct imports

* provider/scaleway: increase timeouts
2016-10-27 16:51:34 +01:00
Andreas Kyrris 59d036202d provider/azurerm: Fix VHD deletion when VM and Storage account are in separate resource groups (#9631)
* Improve messaging when storage account isn't found.

* Add client for finding resources when you don't know it's resource group.

* Add function to find Storage Account resource group name.

* Use the storage account resource group, not the virtual machine's resource group when deleting VHDs.

* Add description of storage account ID for clarity.

* Improve VHD deletion test when storage account is in different resource group.

* Use common function for ID parsing of storage account.
2016-10-27 16:42:47 +01:00
Dana Hoffman 8ae5f3a38c Add subnetwork_project field to allow for XPN in GCE instances 2016-10-27 08:25:58 -07:00
Kit Ewbank 3818720fd4 provider/aws: Data source to provides details about a specific AWS prefix list (#9566)
* Add AWS Prefix List data source.

AWS Prefix List data source acceptance test.

AWS Prefix List data source documentation.

* Improve error message when PL not matched.
2016-10-27 14:58:24 +01:00
Anshul Sharma bc42229b3d Added WAF ACL Resource (#8852) 2016-10-27 12:54:36 +01:00
Raphael Randschau ec20f800b2 provider/scaleway speedup server deletion (#9491)
* provider/scaleway speedup server deletion

using `terminate` instead of `poweroff` leads to a faster shutdown

fixes #9430

* provider/scaleway: extract server shutdown code
2016-10-27 12:37:40 +01:00
stack72 d262ccec1f
Merge branch 'master' of github.com:hashicorp/terraform 2016-10-27 12:14:02 +01:00
stack72 b3a0145d8c
provider/aws: Fixing the acceptance test for ALB AccessLogs Enabling
toggle

```
% make testacc TEST=./builtin/providers/aws
% TESTARGS='-run=TestAccAWSALB_'
% ✹ ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/27 12:04:29 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSALB_ -timeout
120m
=== RUN   TestAccAWSALB_basic
--- PASS: TestAccAWSALB_basic (61.86s)
=== RUN   TestAccAWSALB_generatedName
--- PASS: TestAccAWSALB_generatedName (63.51s)
=== RUN   TestAccAWSALB_namePrefix
--- PASS: TestAccAWSALB_namePrefix (61.93s)
=== RUN   TestAccAWSALB_tags
--- PASS: TestAccAWSALB_tags (95.84s)
=== RUN   TestAccAWSALB_noSecurityGroup
--- PASS: TestAccAWSALB_noSecurityGroup (60.01s)
=== RUN   TestAccAWSALB_accesslogs
--- PASS: TestAccAWSALB_accesslogs (156.99s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws500.162s
```
2016-10-27 12:12:00 +01:00
Peter McAtominey acb6d68120 provider/azurerm: lower servicebus_topic max size to Azure limit, fix test (#9649)
This test was previously passing but the limit appears to have been reduced
since.

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMServiceBusTopic_enableParti -timeout 120m
=== RUN   TestAccAzureRMServiceBusTopic_enablePartitioning
--- PASS: TestAccAzureRMServiceBusTopic_enablePartitioning (377.14s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	377.235s
2016-10-27 12:05:54 +01:00
stack72 54cca9b4fb
Merge branch 'master' of https://github.com/jvasallo/terraform into jvasallo-master 2016-10-27 11:00:48 +01:00
Daniel Portella 11b3b7cf29 provider/docker: Fixes for docker_container host object and documentation (#9367)
* Updated docker container documentation

Feedback from ticket #9350 indicated that documentation was out of date

renamed `hosts_entry` to `host`
added correct type information to *Extra Hosts* section.

Refs: 9350

* Fixes for docker_container host object

Feedback from ticket #9350 updated codebase so it reflects the requirements from docker in regards to `host` which is `Required` and not optional.
It now accurately reflects the docker requirements and the terraform documentation.

Test results

> Bear in mind the failure it is because my laptop doesnt support memory swap. So this test will always fail.

Changing the Schema from `optional` to `required` made no difference to the tests.

make testacc TEST=./builtin/providers/docker/
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/14 15:04:40 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/docker/ -v  -timeout 120m
=== RUN   TestAccDockerRegistryImage_basic
--- PASS: TestAccDockerRegistryImage_basic (4.57s)
=== RUN   TestAccDockerRegistryImage_private
--- PASS: TestAccDockerRegistryImage_private (6.22s)
=== RUN   TestProvider
--- PASS: TestProvider (0.00s)
=== RUN   TestProvider_impl
--- PASS: TestProvider_impl (0.00s)
=== RUN   TestAccDockerContainer_basic
--- PASS: TestAccDockerContainer_basic (7.16s)
=== RUN   TestAccDockerContainer_volume
--- PASS: TestAccDockerContainer_volume (7.37s)
=== RUN   TestAccDockerContainer_customized
--- FAIL: TestAccDockerContainer_customized (18.99s)
	testing.go:265: Step 0 error: Check failed: Check 2/2 error: Container has wrong memory swap setting: -1
	Please check that you machine supports memory swap (you can do that by running 'docker info' command).
=== RUN   TestAccDockerImage_basic
--- PASS: TestAccDockerImage_basic (2.58s)
=== RUN   TestAccDockerImage_private
--- PASS: TestAccDockerImage_private (2.70s)
=== RUN   TestAccDockerImage_destroy
--- PASS: TestAccDockerImage_destroy (30.00s)
=== RUN   TestAccDockerImage_data
--- PASS: TestAccDockerImage_data (5.93s)
=== RUN   TestAccDockerNetwork_basic
--- PASS: TestAccDockerNetwork_basic (0.24s)
=== RUN   TestAccDockerVolume_basic
--- PASS: TestAccDockerVolume_basic (0.05s)
FAIL
exit status 1
FAIL	github.com/hashicorp/terraform/builtin/providers/docker	85.816s
Makefile:47: recipe for target 'testacc' failed
make: *** [testacc] Error 1

Refs: 9350
2016-10-27 10:54:05 +01:00
Peter McAtominey d920105440 provider/azurerm: support importing of subnet resource (#9646)
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMSubnet -timeout 120m
=== RUN   TestAccAzureRMSubnet_importBasic
--- PASS: TestAccAzureRMSubnet_importBasic (165.04s)
=== RUN   TestAccAzureRMSubnet_basic
--- PASS: TestAccAzureRMSubnet_basic (165.39s)
=== RUN   TestAccAzureRMSubnet_disappears
--- PASS: TestAccAzureRMSubnet_disappears (170.02s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	500.533s
2016-10-27 10:20:45 +01:00
Sander van Harmelen 1619a8138f provider/cloudstack: enhance security groups and rules (#9645)
* govendor: update go-cloudstack dependency

* Separate security groups and rules

This commit separates the creation and management of security groups and security group rules.

It extends the `icmp` options so you can supply `icmp_type` and `icmp_code` to enbale more specific configs.

And it adds lifecycle management of security group rules, so that security groups do not have to be recreated when rules are added or removed.

This is particulary helpful since the `cloudstack_instance` cannot update a security group without having to recreate the instance.

In CloudStack >= 4.9.0 it is possible to update security groups of existing instances, but as that is just added to the latest version it seems a bit too soon to start using this (causing backwards incompatibility issues for people or service providers running older versions).

* Add and update documentation

* Add acceptance tests
2016-10-27 11:10:15 +02:00
James Nugent 54e4deb3e3 provider/aws: Suceed deleting bucket policy on err (#9641)
If there is no bucket, a bucket policy can be counted as successfully
deleted.
2016-10-26 23:16:54 +01:00
Joe Topjian a946eb4d91 Merge pull request #9617 from jtopjian/openstack-fwaas-proto-any
provider/openstack: Allow any protocol in openstack_fw_rule_v1
2016-10-26 12:56:11 -06:00
Joe Topjian 5016325de0 Merge pull request #9554 from fatmcgav/openstack_compute_keypair_add_value_specs
provider/openstack: Add 'value_specs' option to 'openstack_compute_keypa…
2016-10-26 12:54:34 -06:00
Daniel Portella c2370c574e Fixes for consul_service resource (#9366)
Added `service_id` in place of `id` for resource.
modified created, read, update to use `service_id`
modified tests to include `service_id`.
modified documentation for consul_service to include new value.

Tests results

CONSUL_HTTP_ADDR=localhost:8500 make testacc TEST=./builtin/providers/consul/

==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/14 14:43:05 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/consul/ -v  -timeout 120m
=== RUN   TestAccDataConsulKeys_basic
--- PASS: TestAccDataConsulKeys_basic (0.05s)
=== RUN   TestAccConsulAgentService_basic
--- PASS: TestAccConsulAgentService_basic (0.05s)
=== RUN   TestAccConsulCatalogEntry_basic
--- PASS: TestAccConsulCatalogEntry_basic (0.06s)
=== RUN   TestAccConsulKeyPrefix_basic
--- PASS: TestAccConsulKeyPrefix_basic (0.19s)
=== RUN   TestConsulKeysMigrateState
--- PASS: TestConsulKeysMigrateState (0.00s)
=== RUN   TestConsulKeysMigrateState_empty
--- PASS: TestConsulKeysMigrateState_empty (0.00s)
=== RUN   TestAccConsulKeys_basic
--- PASS: TestAccConsulKeys_basic (0.13s)
=== RUN   TestAccConsulNode_basic
--- PASS: TestAccConsulNode_basic (0.05s)
=== RUN   TestAccConsulPreparedQuery_basic
--- PASS: TestAccConsulPreparedQuery_basic (0.12s)
=== RUN   TestAccConsulService_basic
--- PASS: TestAccConsulService_basic (0.05s)
=== RUN   TestResourceProvider
--- PASS: TestResourceProvider (0.00s)
=== RUN   TestResourceProvider_impl
--- PASS: TestResourceProvider_impl (0.00s)
=== RUN   TestResourceProvider_Configure
--- PASS: TestResourceProvider_Configure (0.00s)
=== RUN   TestResourceProvider_ConfigureTLS
--- PASS: TestResourceProvider_ConfigureTLS (0.00s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/consul	0.708s

Refs: #9352
2016-10-26 13:07:00 +01:00
Krzysztof Wilczynski 44614c6765 provider/aws: Validate regular expression passed via the `name_regex` attribute. (#9622)
* Clean-up for Go 1.7+ version.

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

* Validate regular expression passed via the `name_regex` attribute.

This commit adds a simple ValidateFunc to check whether the regular
expression that was passed down via the `name_regex` attribute is valid.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-26 12:09:14 +01:00
Mickaël Canévet d030b62b0b Cloudstack security group (#9103)
* Add cloudstack_security_group resource

* Update github.com/xanzy/go-cloudstack/cloudstack

* Add support for security_group

* Add documentation for cloudstack_security_group
2016-10-26 09:29:37 +02:00
Gavin Williams 7438bbd7fe provider/openstack: Add ValueSpecs option to 'openstack_compute_keypair_v2' resource,
refactor to use common types.go and 'MapValueSpecs'
2016-10-26 07:50:35 +01:00
Joe Topjian d7bd40100c provider/openstack: Allow any protocol in openstack_fw_rule_v1
This commit allows a protocol of "any" to be used in the firewall
rule resource, which will allow any protocol.
2016-10-26 02:14:08 +00:00
Joe Topjian 3929792ebc Merge pull request #9552 from fatmcgav/openstack_networking_floatingip_add_value_specs
provider/openstack: Add 'value_specs' option to 'openstack_networking…
2016-10-25 19:35:38 -06:00
Joe Topjian 1d6695139d Merge pull request #9551 from fatmcgav/openstack_networking_port_add_value_specs
provider/openstack: Add value_specs option to `openstack_networking_port_v2`
2016-10-25 19:35:15 -06:00
James Nugent eb17741d26 Merge pull request #9605 from hashicorp/keybase-aws-login-profile
provider/aws: aws_iam_user_login_profile resource
2016-10-25 20:09:42 -05:00
dario-simonetti dbdaf20a19 provider/aws: fix aws_elasticache_replication_group for Redis in cluster mode (#9601)
This is a fix for issue https://github.com/hashicorp/terraform/issues/9596.

Changes:
 - Adds new output attribute `configuration_endpoint_address`. Only
   used in Redis when in cluster mode.
 - Read the `snapshot_window` and `snapshot_retention_limit` from
   the
   replication group description instead of the cache cluster
   description.
 - Adds acceptance test and modifies an existing acceptance test to
   make sure that everything is still good in non-cluster mode
 - Updates docs to describe new output attribute
2016-10-25 23:59:54 +01:00
James Nugent e5bda11a2d provider/aws: Add tests with bad keys
Add a test with a bad explicitly specified GPG key and a keybase user
(that we own) with no public keys.
2016-10-25 16:27:34 -05:00
James Nugent 2e046232a0 provider/aws: Add Login Profile acceptance tests 2016-10-25 16:16:57 -05:00
Mitchell Hashimoto 8dcd5881f9
providers/azurerm: don't leak the context cancellation function 2016-10-25 12:08:36 -07:00
Mitchell Hashimoto 5ee8042dff
helper/schema: expose stop information as a Context 2016-10-25 12:08:36 -07:00
Mitchell Hashimoto 990df480dc
providers/azurerm: convert to Stop() usage as example 2016-10-25 12:08:36 -07:00
Mitchell Hashimoto 60140b28f4
Revert "Merge pull request #9536 from hashicorp/f-provider-stop"
This reverts commit c3a4cff133, reversing
changes made to 791a02e6e4.

This change requires plugin recompilation and we should hold off until a
minor release for that.
2016-10-25 12:00:36 -07:00
Mitchell Hashimoto d7402d0473
providers/azurerm: don't leak the context cancellation function 2016-10-25 11:47:47 -07:00
Mitchell Hashimoto 86eb30b8a2
helper/schema: expose stop information as a Context 2016-10-25 11:32:30 -07:00
Mitchell Hashimoto 9089aa24d5
providers/azurerm: convert to Stop() usage as example 2016-10-25 11:32:17 -07:00
James Nugent e5fb6c9b23 provider/aws: Don't fail if login profile exists
If an IAM user already has a login profile, we bring it under management
- we will NOT modify it - but we cannot set the password.
2016-10-25 13:22:14 -05:00
James Nugent dba3ec2f5d provider/aws: Adhere to policy for login profiles
This commit modifies password generation such that it is highly likely
to match any AWS password policy.
2016-10-25 12:57:35 -05:00
James Nugent 513c2f9720 provider/aws: aws_iam_user_login_profile resource
This commit introduces an `aws_iam_user_login_profile` resource which
creates a password for an IAM user, and encrypts it using a PGP key
specified in the configuration or obtained from Keybase.

For example:

```
resource "aws_iam_user" "u" {
        name = "auser"
        path = "/"
        force_destroy = true
}

resource "aws_iam_user_login_profile" "u" {
        user = "${aws_iam_user.u.name}"
        pgp_key = "keybase:some_person_that_exists"
}

output "password" {
	value = "${aws_iam_user_login_profile.u.encrypted_password}"
}
```

The resulting attribute "encrypted_password" can be decrypted using
PGP or Keybase - for example:

```
terraform output password | base64 --decode | keybase pgp decrypt
```

Optionally the user can retain the password rather than the default of
being forced to change it at first login. Generated passwords are
currently 20 characters long.
2016-10-25 12:08:50 -05:00
Jonathan Rudenberg d265a6fee3 provider/azurerm: Add disk_size_gb param to VM storage_os_disk (#9200)
TF_ACC=1 go test ./builtin/providers/azurerm -v -run=TestAccAzureRMVirtualMachine_basicLinuxMachine -timeout 120m
    === RUN   TestAccAzureRMVirtualMachine_basicLinuxMachine
    --- PASS: TestAccAzureRMVirtualMachine_basicLinuxMachine (540.83s)
    PASS
    ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	540.841s

    TF_ACC=1 go test ./builtin/providers/azurerm -v -run=TestAccAzureRMVirtualMachine_withDataDisk -timeout 120m
    === RUN   TestAccAzureRMVirtualMachine_withDataDisk
    --- PASS: TestAccAzureRMVirtualMachine_withDataDisk (431.19s)
    PASS
    ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	431.203s
2016-10-25 17:54:55 +01:00
ddcprg 47e079b77b Support for Service Access Security Group 2016-10-25 16:55:09 +01:00
Peter McAtominey c199d1fde2 provider/azurerm: fix servicebus_topic updating values (#9323)
enable_partitioning set to ForceNew
requires_duplicate_detection set to ForceNew

max_size_in_megabytes would cause a loop if enable_partitioning was true as this
causes the value to be multiplied by 16 for it's effective value, this computed
value is then returned by the ARM API in the same field which caused Terraform
to always detect a change

```
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMServiceBusTopic -timeout 120m
=== RUN   TestAccAzureRMServiceBusTopic_importBasic
--- PASS: TestAccAzureRMServiceBusTopic_importBasic (345.08s)
=== RUN   TestAccAzureRMServiceBusTopic_basic
--- PASS: TestAccAzureRMServiceBusTopic_basic (342.23s)
=== RUN   TestAccAzureRMServiceBusTopic_update
--- PASS: TestAccAzureRMServiceBusTopic_update (359.56s)
=== RUN   TestAccAzureRMServiceBusTopic_enablePartitioning
--- PASS: TestAccAzureRMServiceBusTopic_enablePartitioning (362.80s)
=== RUN   TestAccAzureRMServiceBusTopic_enableDuplicateDetection
--- PASS: TestAccAzureRMServiceBusTopic_enableDuplicateDetection (364.97s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	1774.657s
```
2016-10-25 16:34:08 +01:00
Ninir ef5ceb9681 Exposed aws_api_gw_domain_name.certificate_upload_date attribute (#9533) 2016-10-25 16:07:08 +01:00
Brad Sickles 65523fa006 provider/archive: Converting to datasource. (#8492)
* Converting archive_file to datasource.

* Ratcheting back new dir perms.

* Ratcheting back new dir perms.

* goimports

* Adding output_base64sha256 attribute to archive_file.

Updating docs.

* Dropping CheckDestroy since this is a data source.

* Correcting data source attribute checks.
2016-10-25 15:59:06 +01:00
Tom Harvey 59a81da74e provider/azurerm: Event Hub Namespaces (#9297)
Add support for EventHub NameSpaces
2016-10-25 15:50:07 +01:00
Paul Stack d485512d71 Merge pull request #9468 from wendorf/arm_loadbalancer_rule_naming_fix
Azure RM loadbalancer rules have correct naming restrictions
2016-10-25 15:12:26 +01:00
Paul Stack c7935a0fd2 Merge pull request #9584 from hashicorp/aws-iam-group-name-validation
provider/aws: Add validation to IAM User and Group Name
2016-10-25 14:23:17 +01:00
Paul Stack a24a068196 Merge pull request #8674 from enieuw/feature/arm_storage_file
provider/azurerm: Implement azurerm_storage_share
2016-10-25 14:16:46 +01:00
Paul Stack df18307662 Merge pull request #9583 from hashicorp/aws-iam-delete-force_destroy
provider/aws: Delete Loging Profile from IAM User on force_destroy
2016-10-25 14:14:49 +01:00
Paul Stack ecb467aa7d Merge pull request #9478 from BedeGaming/azurerm-keyvault
provider/azurerm: key_vault resource and client_config datasource
2016-10-25 13:35:29 +01:00
stack72 79557bca80
provider/aws: Add validation to IAM User and Group Name
This will allow us to catch errors at plan time rather than waiting for
the API to tell us...

Documentation for IAM User NAme Validation -
http://docs.aws.amazon.com/cli/latest/reference/iam/create-user.html

Documentation for IAM Group Name validation -
http://docs.aws.amazon.com/cli/latest/reference/iam/create-group.html

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSIAMGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/25 13:18:41 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSIAMGroup_
-timeout 120m
=== RUN   TestAccAWSIAMGroup_importBasic
--- PASS: TestAccAWSIAMGroup_importBasic (13.80s)
=== RUN   TestAccAWSIAMGroup_basic
--- PASS: TestAccAWSIAMGroup_basic (23.30s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws37.121s
```

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSUser_'                                                                 ✚
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/25 13:22:23 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSUser_ -timeout 120m
=== RUN   TestAccAWSUser_importBasic
--- PASS: TestAccAWSUser_importBasic (14.33s)
=== RUN   TestAccAWSUser_basic
--- PASS: TestAccAWSUser_basic (25.36s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	39.710s
```
2016-10-25 13:18:41 +01:00
Peter McAtominey e7d64b28bd provider/azurerm: add key_vault resource
- vendor keyvault sdk package

```
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMKeyV -timeout 120m
=== RUN   TestAccAzureRMKeyVault_importBasic
--- PASS: TestAccAzureRMKeyVault_importBasic (89.01s)
=== RUN   TestAccAzureRMKeyVault_basic
--- PASS: TestAccAzureRMKeyVault_basic (83.36s)
=== RUN   TestAccAzureRMKeyVault_update
--- PASS: TestAccAzureRMKeyVault_update (102.83s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	275.285s
```
2016-10-25 13:01:45 +01:00
stack72 2dcc6b8ef0
provider/aws: Delete Loging Profile from IAM User on force_destroy
When force_Destroy was specified on an iam_user, only Access Keys were
destroyed. Therefore, if a password was manually added via the AWS
console, it was causing an error as follows:

```
* aws_iam_user.user: Error deleting IAM User test-user-for-profile-delete: DeleteConflict: Cannot delete entity, must delete login profile first.
    status code: 409, request id: acd67e40-9aa8-11e6-8533-4db80bad7ea8
```

We now *try* to delete the LoginProfile and ignore a NoSuchEntity error
if it doesn't exist

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSUser_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/25 12:53:05 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSUser_
-timeout 120m
=== RUN   TestAccAWSUser_importBasic
--- PASS: TestAccAWSUser_importBasic (14.83s)
=== RUN   TestAccAWSUser_basic
--- PASS: TestAccAWSUser_basic (24.78s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws39.624s
```
2016-10-25 12:56:30 +01:00
Paul Stack a65dc539ac Merge pull request #9504 from hashicorp/aws-redshift-sng-tags
provider/aws: Add tagging support to aws_redshift_subnet_group
2016-10-25 11:48:16 +01:00
stack72 ff60fa3aa1
provider/digitalocean: Ingore resize_disk on the import DO droplet tests
```
% make testacc TEST=./builtin/providers/digitalocean
% TESTARGS='-run=TestAccDigitalOceanDroplet_importBasic'
% 2 ↵
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/25 11:39:26 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/digitalocean -v
-run=TestAccDigitalOceanDroplet_importBasic -timeout 120m
=== RUN   TestAccDigitalOceanDroplet_importBasic
--- PASS: TestAccDigitalOceanDroplet_importBasic (56.04s)
PASS
ok
github.com/hashicorp/terraform/builtin/providers/digitalocean56.049s
```
2016-10-25 11:40:56 +01:00
Andrew Starr-Bochicchio ccff5af8e7 Allow resizing DigitalOcean Droplets without increasing disk size. 2016-10-24 20:00:04 -04:00
Clint 0c4526fbad Merge pull request #9561 from hashicorp/b-aws-vpc-endpoint-refresh
provider/aws: Remove VPC Endpoint from state if it's not found
2016-10-24 14:25:21 -05:00
Clint 7c58896f30 Merge pull request #9560 from hashicorp/b-aws-computed-public-ip
provider/aws: Make associate_public_ip_address computed
2016-10-24 14:21:44 -05:00
clint shryock 85dd379974 provider/aws: Remove VPC Endpoint from state if it's not found 2016-10-24 14:17:58 -05:00
Mitchell Hashimoto bb5f6498e2
provider/nomad 2016-10-24 10:34:06 -07:00
clint shryock c014dac279 provider/aws: Make associate_public_ip_address computed 2016-10-24 11:24:54 -05:00
Paul Stack 765dc19286 Merge pull request #9022 from heimweh/master
Adding PagerDuty provider
2016-10-24 17:07:22 +01:00
Gavin Williams 60ddc06b3d provider/openstack: Add 'value_specs' option to 'openstack_networking_floatingip_v2' resource,
refactor into common types.go and use new 'MapValueSpecs' function.
Added supporting documentation.
2016-10-24 16:05:35 +01:00
Gavin Williams b31b044785 provider/openstack: Add value_specs option to openstack_networking_port_v2.
Refactored to use common types.go
Add supporting documentation
2016-10-24 16:04:00 +01:00
Alexander Hellbom 4b70654b57 Remove the unnecessary use of &schema.Schema 2016-10-24 16:43:53 +02:00
Paul Stack eaee3b9d78 Merge pull request #9442 from obsh/google-scope-aliases
provider/google: add scope aliases
2016-10-24 14:36:51 +01:00
Paul Stack f7d4110b2d Merge pull request #9455 from BedeGaming/azurerm-lb-concurrency-fix
provider/azurerm: lock mutex in load_balancer resources
2016-10-24 14:29:29 +01:00
Paul Stack 3f16f3d4c9 Merge pull request #9207 from BedeGaming/azurerm-nic-hash
provider/azurerm: write load_balanacer attributes to network_interface_card hash
2016-10-24 14:26:20 +01:00
Paul Stack b35ab4de62 Merge pull request #9307 from BedeGaming/azurerm-tags-computed-fix
provider/azurerm: fix computed tags causing non-empty plan
2016-10-24 14:20:00 +01:00
Paul Stack 7ac85e9f6d Merge pull request #9408 from BedeGaming/azurerm-storage-account-tier
provider/azurerm: add account_kind and access_tier to storage_account
2016-10-24 14:15:34 +01:00
Alexander Hellbom 4c45c790c3 Add support for teams in escalation policies & vendor support 2016-10-24 15:01:35 +02:00
stack72 52f2717bfb
provider/aws: Add tagging support to aws_redshift_subnet_group
Fixes #9492

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSRedshiftSubnetGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/10/21 17:16:02 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSRedshiftSubnetGroup_ -timeout 120m
=== RUN   TestAccAWSRedshiftSubnetGroup_importBasic
--- PASS: TestAccAWSRedshiftSubnetGroup_importBasic (86.54s)
=== RUN   TestAccAWSRedshiftSubnetGroup_basic
--- PASS: TestAccAWSRedshiftSubnetGroup_basic (85.50s)
=== RUN   TestAccAWSRedshiftSubnetGroup_updateSubnetIds
--- PASS: TestAccAWSRedshiftSubnetGroup_updateSubnetIds (140.01s)
=== RUN   TestAccAWSRedshiftSubnetGroup_tags
--- PASS: TestAccAWSRedshiftSubnetGroup_tags (136.02s)
PASS
ok	github.com/hashicorp/terraform/builtin/providers/aws	448.075
```
2016-10-24 13:44:46 +01:00
Alexander Hellbom b40ba1042f escalation_rule -> rule 2016-10-24 14:19:59 +02:00
Alexander Hellbom a6abce7e60 schedule_layer -> layer 2016-10-24 14:19:59 +02:00
Alexander Hellbom 97e48f659f Add data source for on call users 2016-10-24 14:19:59 +02:00
Alexander Hellbom 9ab1093633 Skip setting the role if owner 2016-10-24 14:19:59 +02:00
Alexander Hellbom b85715ea51 bump go-pagerduty 2016-10-24 14:19:59 +02:00
Alexander Hellbom fff166dca7 Adding status, created_at & last_incident_timestamp for service 2016-10-24 14:19:59 +02:00
Alexander Hellbom ec10e031ee Make Schedule work and add tests for import and resource + cleanups 2016-10-24 14:19:58 +02:00
Alexander Hellbom ffd3ceef0d Add schedule test 2016-10-24 14:19:58 +02:00
Alexander Hellbom de9a1c146c Allowed values in error message 2016-10-24 14:19:58 +02:00
Alexander Hellbom effec42278 Add service type validation 2016-10-24 14:19:58 +02:00
Alexander Hellbom ee20c11907 Simplify role check for user 2016-10-24 14:19:58 +02:00
Alexander Hellbom 0951adab3b Check for errors when setting schedule_layer 2016-10-24 14:19:57 +02:00
Alexander Hellbom 35312f0066 Simplify setting up EscalationPolicy 2016-10-24 14:19:57 +02:00
Alexander Hellbom 69fb733ad0 Check for errors when setting escalation_rule 2016-10-24 14:19:57 +02:00
Alexander Hellbom 3fae0454bf Fix diff bug 2016-10-24 14:19:57 +02:00
Alexander Hellbom d786c1cf68 Add test case for user with teams 2016-10-24 14:19:56 +02:00
Alexander Hellbom 074e989846 Fix up tests 2016-10-24 14:19:56 +02:00
Alexander Hellbom 9e81677354 Add support for service integration 2016-10-24 14:19:56 +02:00
Alexander Hellbom d02067a75e Add PagerDuty provider 2016-10-24 14:19:55 +02:00
stack72 c4e2ff9cbb
provider/scaleway: Change bootscript datasource acceptance test
The tests were referencing an old bootscript - this just bumps the value
to the latest. The list of bootscripts can be found at
http://devhub.scaleway.com/#/bootscripts
2016-10-24 13:11:41 +01:00
Joe Topjian 17b1787ec2 provider/openstack: gophercloud migration: fixing dhcp and gateway configuration 2016-10-23 02:38:29 +00:00
Joe Topjian 1c6b69e342 provider/openstack: gophercloud migration: Make PortID a *string 2016-10-23 02:38:29 +00:00
Joe Topjian 0253dbe51b provider/openstack: gophercloud migration: Accounting for 409 errors with LBaaSV2 2016-10-23 02:38:29 +00:00
Joe Topjian 1fce3ed9fd provider/openstack: gophercloud migration: Fixing persistence update in lbaasv1 2016-10-23 02:38:28 +00:00
Joe Topjian fbcd8f105b provider/openstack: gophercloud migration: boot from volume updates 2016-10-23 02:38:28 +00:00
Joe Topjian ea4209c61c provider/openstack: gophercloud migration: Account for subnets and networks still in use 2016-10-23 02:38:28 +00:00
Joe Topjian 394c26c6cc provider/openstack: gophercloud migration: Account for router interface still being in use 2016-10-23 02:38:27 +00:00
Joe Topjian 7df2a66623 provider/openstack: gophercloud migration: Allow Firewall v1 Policy to cleanly delete 2016-10-23 02:38:27 +00:00
Joe Topjian c3679d6c2d provider/openstack: gophercloud migration: Fixing subnet test 2016-10-23 02:38:27 +00:00
Joe Topjian ed0fe74d59 provider/openstack: gophercloud migration: Making GatewayIP computed 2016-10-23 02:38:27 +00:00
Joe Topjian 520b3dda82 provider/openstack: gophercloud migration: Spelling correction 2016-10-23 02:38:26 +00:00
Gavin Williams 28466f50a5 provider/openstack: gophercloud migration: Only set 'gateway_ip' to "" if 'no_gateway' == true. 2016-10-23 02:38:26 +00:00
Gavin Williams 8405a9f118 provider/openstack: gophercloud migration: Update openstack_networking_subnet_v2 to correctly handle Gateway IP 2016-10-23 02:38:26 +00:00
Gavin Williams 9c856a8f6f provider/openstack: gophercloud migration: Removed unused import from types.go 2016-10-23 02:38:26 +00:00
Gavin Williams e7ef8bb647 provider/openstack: gophercloud migration: Ordering tweak in types.go - Now alphabetical :) 2016-10-23 02:38:25 +00:00
Gavin Williams bfab530410 provider/openstack: gophercloud migration: Migrate NetworkCreateOpts to types.go 2016-10-23 02:38:25 +00:00
Gavin Williams 58c3c4ef8e provider/openstack: gophercloud migration: Migrate RouterCreateOpts to types.go 2016-10-23 02:38:25 +00:00
Gavin Williams 56cc232956 provider/openstack: gophercloud migration: Refactor existing resources to use 'MapValueSpecs' function 2016-10-23 02:38:24 +00:00
Gavin Williams ffd5370213 provider/openstack: gophercloud migration: Add a 'MapValueSpecs' function which can be used to convert
'value_specs' resource data to a map.
2016-10-23 02:38:24 +00:00
Gavin Williams 796e076313 provider/openstack: gophercloud migration: Use 'value_specs' from constructed body, and range over asserted type 2016-10-23 02:38:24 +00:00
Gavin Williams 1eab2121ad provider/openstack: gophercloud migration: Add a BuildRequest function, and refactor types 'SubnetCreateMap' function to use 2016-10-23 02:38:24 +00:00
Gavin Williams edf80d2ae1 provider/openstack: gophercloud migration: Use 'log.Printf' rather than 'log.Println'. 2016-10-23 02:38:23 +00:00
Gavin Williams a823370a48 provider/openstack: gophercloud migration: Fix handling of Neutron networking when managing instances. 2016-10-23 02:38:23 +00:00
Joe Topjian e36c3e5946 provider/openstack: gophercloud migration: Continued removal of APIKey 2016-10-23 02:38:23 +00:00
Joe Topjian d4722aedc1 provider/openstack: gophercloud migration: initial work on types.go 2016-10-23 02:38:22 +00:00
Joe Topjian 27b86ac220 provider/openstack: gophercloud migration: metadata update 2016-10-23 02:38:22 +00:00
Joe Topjian 8371d20cf0 provider/openstack: gophercloud migration: router interface error response 2016-10-23 02:38:22 +00:00
Joe Topjian 8f21117fb7 provider/openstack: gophercloud migration: fwaas policy response error handling 2016-10-23 02:38:22 +00:00
Joe Topjian c11a4ef214 provider/openstack: gophercloud migration: updating error responses 2016-10-23 02:38:22 +00:00
Joe Topjian 9ffef951c5 provider/openstack: gophercloud migration: objectstorage 2016-10-23 02:38:21 +00:00
Joe Topjian d5bf0197a7 provider/openstack: gophercloud migration: networking subnet 2016-10-23 02:38:21 +00:00
Joe Topjian f2ba380794 provider/openstack: gophercloud migration: networking secgroup 2016-10-23 02:38:21 +00:00
Joe Topjian 2f957e24fe provider/openstack: gophercloud migration: networking router 2016-10-23 02:38:20 +00:00
Joe Topjian 53bb3187fc provider/openstack: gophercloud migration: networking port 2016-10-23 02:38:20 +00:00
Joe Topjian 68c4956ff2 provider/openstack: gophercloud migration: networking network 2016-10-23 02:38:20 +00:00
Joe Topjian cc86b91d37 provider/openstack: gophercloud migration: networking floatingip 2016-10-23 02:38:20 +00:00
Joe Topjian d04cfb1ab5 provider/openstack: gophercloud migration: lbaas v2 2016-10-23 02:38:19 +00:00
Joe Topjian e2526002ff provider/openstack: gophercloud migration: lbaas v1 2016-10-23 02:38:19 +00:00
Joe Topjian a1d76c8d07 provider/openstack: gophercloud migration: fwaas 2016-10-23 02:38:19 +00:00
Joe Topjian 8b6c3a1bbc provider/openstack: gophercloud migration: compute servergroup 2016-10-23 02:38:19 +00:00
Joe Topjian b9f7d119b8 provider/openstack: gophercloud migration: compute secgroup 2016-10-23 02:38:18 +00:00
Joe Topjian 50855b3992 provider/openstack: gophercloud migration: compute keypair 2016-10-23 02:38:18 +00:00
Joe Topjian a33256706c provider/openstack: gophercloud migration: compute instance 2016-10-23 02:38:18 +00:00
Joe Topjian c8aee9118f provider/openstack: gophercloud migration: compute floatingip 2016-10-23 02:38:17 +00:00
Joe Topjian bb8c5cea2d provider/openstack: gophercloud migration: blockstorage 2016-10-23 02:38:17 +00:00
Joe Topjian e677eaac6b provider/openstack: gophercloud migration: util 2016-10-23 02:38:17 +00:00
Joe Topjian 74f990ff5c provider/openstack: gophercloud migration: Removing APIKey Attribute
gophercloud/gophercloud no longer supports the APIKey authentication
attribute. Removal of this attribute may impact users who were using
the Terraform OpenStack provider in with vendor-modified clouds.
2016-10-23 02:38:17 +00:00
Radek Simko eda1298e21 provider/aws: Increase ECS service drain timeout (#9521) 2016-10-22 14:16:59 +01:00
Clint dcbcde4b82 Merge pull request #8893 from dennis-bsi/fix-asg-policy-to-0
provider/aws: aws_autoscaling_policy fails when setting scaling_adjustment to 0 for SimpleScaling
2016-10-21 16:17:16 -05:00
Clint 6f7e9ac4dd Merge pull request #9511 from dennis-bsi/aws-redshift-sng-name-validation
provider/aws: limiting aws_redshift_subnet_group name to alphanumeric and hyphens
2016-10-21 14:35:53 -05:00
Clint 88925eb939 Merge pull request #9515 from dennis-bsi/aws-redshift-sng-description-update
provider/aws: aws_redshift_subnet_group allows description to be modified
2016-10-21 14:32:34 -05:00
Dennis Webb dac69b7919 fixing issue where changing only the description only didn't actually update on AWS 2016-10-21 12:14:41 -05:00
Clint 34b21083ee Merge pull request #8983 from 987poiuytrewq/b-aws-beanstalk-option-updates
provider/aws: fix option updates to beanstalk
2016-10-21 11:43:43 -05:00
clint shryock 3fbf01ea1b provider/aws: Bump AWS Route retry to 2 minutes, up from 15 seconds 2016-10-21 11:36:51 -05:00
Dennis Webb 05783ca044 limiting subnetgroup name to alphanumeric and hyphens 2016-10-21 11:28:48 -05:00
Paul Stack 7d7da4b6b6 Merge pull request #9456 from kwilczynski/feature/rename-file-aws_availability_zones
provider/aws: Rename the file to match the naming scheme.
2016-10-21 14:38:03 +04:00
clint shryock aa9c420586 slight rename and sorting of test 2016-10-20 16:16:01 -05:00
Clint e6c2b7f19c Merge pull request #9357 from mrwacky42/f/vpce-empty-rtb
Allow empty route_table_ids list in aws_vpc_endpoint resources
2016-10-20 16:13:06 -05:00
clint shryock 77075d0573 provider/datadog: Reduce diff on thresholds 2016-10-20 10:22:24 -05:00
Peter McAtominey 6f72b2c36a provider/azurerm: lock mutex in load_balancer resources
This fixes races between sub resources causing inconsistent writes of the load
balancer resource

Fixes #9424

```
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMLoadBalancer -timeout 120m
=== RUN   TestAccAzureRMLoadBalancerBackEndAddressPool_basic
--- PASS: TestAccAzureRMLoadBalancerBackEndAddressPool_basic (150.95s)
=== RUN   TestAccAzureRMLoadBalancerBackEndAddressPool_removal
--- PASS: TestAccAzureRMLoadBalancerBackEndAddressPool_removal (146.25s)
=== RUN   TestAccAzureRMLoadBalancerNatPool_basic
--- PASS: TestAccAzureRMLoadBalancerNatPool_basic (157.43s)
=== RUN   TestAccAzureRMLoadBalancerNatPool_removal
--- PASS: TestAccAzureRMLoadBalancerNatPool_removal (169.46s)
=== RUN   TestAccAzureRMLoadBalancerNatRule_basic
--- PASS: TestAccAzureRMLoadBalancerNatRule_basic (149.04s)
=== RUN   TestAccAzureRMLoadBalancerNatRule_removal
--- PASS: TestAccAzureRMLoadBalancerNatRule_removal (170.35s)
=== RUN   TestAccAzureRMLoadBalancerProbe_basic
--- PASS: TestAccAzureRMLoadBalancerProbe_basic (146.88s)
=== RUN   TestAccAzureRMLoadBalancerProbe_removal
--- PASS: TestAccAzureRMLoadBalancerProbe_removal (166.25s)
=== RUN   TestAccAzureRMLoadBalancerRule_basic
--- PASS: TestAccAzureRMLoadBalancerRule_basic (146.36s)
=== RUN   TestAccAzureRMLoadBalancerRule_removal
--- PASS: TestAccAzureRMLoadBalancerRule_removal (164.24s)
=== RUN   TestAccAzureRMLoadBalancerRule_inconsistentReads
--- PASS: TestAccAzureRMLoadBalancerRule_inconsistentReads (153.19s)
=== RUN   TestAccAzureRMLoadBalancer_basic
--- PASS: TestAccAzureRMLoadBalancer_basic (102.59s)
=== RUN   TestAccAzureRMLoadBalancer_frontEndConfig
--- PASS: TestAccAzureRMLoadBalancer_frontEndConfig (187.92s)
=== RUN   TestAccAzureRMLoadBalancer_tags
--- PASS: TestAccAzureRMLoadBalancer_tags (119.93s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	2130.930s
```
2016-10-20 14:59:01 +01:00
Peter McAtominey 6374cc7d33 provider/azurerm: add client_config data source
azurerm_client_config provides access to:

 - client_id
 - tenant_id
 - subscription_id

```
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMClientConfig -timeout 120m
=== RUN   TestAccAzureRMClientConfig_basic
--- PASS: TestAccAzureRMClientConfig_basic (27.79s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	27.862s
```
2016-10-20 11:29:48 +01:00
Dan Wendorf 957d1cb3a8 Azure RM loadbalancer rules have correct naming restrictions
- The name cannot be empty
- The name cannot be more than 80 characters
- The name must begin with a letter or number
- The name must end with a letter, number, or underscore
- The name must only contain letters, numbers, underscores, periods, or hyphens
2016-10-19 17:58:44 -07:00
oleksandr.bushkovskyi f9b6d2df8f provider/google: add scope aliases 2016-10-19 23:14:55 +03:00
Krzysztof Wilczynski 219efaa64f
Rename the file to match the naming scheme.
This commit is a maintenance change aimed at aligning file names so that they
fall in line with the established naming convention.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-19 16:34:35 +01:00
Clint 7b9e58423c Merge pull request #9453 from tomwilkie/8187-import-associate_public_ip_address
Infer aws_instance.associate_public_ip_address from the presence of a network interface association.
2016-10-19 10:24:34 -05:00
Tom Wilkie e79ebfc113 Infer aws_instance.associate_public_ip_address from the presence of a network interface association. 2016-10-19 16:16:04 +01:00
clint shryock bdb60893d5 provider/aws: Update ElastiCache tests to redis 3.2 2016-10-19 09:48:15 -05:00
clint shryock 22b3e8998d Merge branch 'master' of github.com:hashicorp/terraform
* 'master' of github.com:hashicorp/terraform:
  Don't assert nil values in convertStringArr
2016-10-19 09:47:30 -05:00
clint shryock 70eb45d1e9 provider/aws: Update ElasticCache cluster redis params for new default 2016-10-19 09:43:27 -05:00
James Bardin e5c6031469 Merge pull request #9451 from hashicorp/jbardin/GH-9428
Don't assert nil values in convertStringArr
2016-10-19 10:26:35 -04:00
clint shryock e90fa6abd4 provider/aws: Tidy up IAM user acc tests 2016-10-19 09:22:27 -05:00
James Bardin 4be35a5e4e Don't assert nil values in convertStringArr
Some of the inputs to this function may not have been validated
2016-10-19 10:06:13 -04:00
James Bardin f175497dd7 Fix vet issues
None were critical, but these will fail with the next version of vet.
2016-10-18 11:11:12 -04:00
James Nugent fc2d973e26 Merge pull request #9387 from nicolai86/feat/scaleway-import
provider/scaleway: add support for importing resources
2016-10-18 08:11:09 -05:00
James Nugent 4ef3ab70f9 Merge branch 'feat/provider-scaleway-bootscript' of https://github.com/nicolai86/terraform into nicolai86-feat/provider-scaleway-bootscript 2016-10-18 08:06:14 -05:00
James Nugent e2f3832769 provider/azurerm: Fix error message wording 2016-10-18 08:00:38 -05:00
James Nugent 760587092a Merge branch 'GH-9311' of https://github.com/carinadigital/terraform into carinadigital-GH-9311 2016-10-18 07:51:37 -05:00
James Nugent 0c4b4a1970 Merge pull request #9429 from hashicorp/f-aws-new-region
aws: Add missing metadata for us-east-2
2016-10-18 07:44:01 -05:00
Krzysztof Wilczynski b74de12bd6
Handle the case where Route Table is already gone.
This commit changes the behaviour of the `ExistsFunc`, where by default
lack of a route table (e.g. already removed, etc.) would cause an error
to be thrown. This makes is hard to carry out any action e.g. plan,
refresh, or destroy, that rely on the route table existance check.

Also, make error messages a little better in terms of wording, etc.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-18 11:56:47 +01:00
Andreas Kyrris 182ebf3abb Use better variable naming. 2016-10-18 10:44:15 +01:00
Radek Simko 4b36bc3210
aws: Add missing metadata for us-east-2 2016-10-18 09:31:57 +01:00
Andreas Kyrris da12ed640a Checking for azure credentials isn't required.
The check for ARM_SUBSCRIPTION_ID breaks the PR testing. The PR
testing isn't trying to check acceptance tests anyway.
There will still be a correct failure for missing ARM_SUBSCRIPTION_ID
when running the acceptance test due to the later testAccPreCheck().
2016-10-18 09:26:36 +01:00
Andreas Kyrris 7b133ad356 Fix id of azurerm_lb_backend_address_pool, azurerm_lb_rule, azurerm_lb_nat_rule, azurerm_lb_nat_pool. 2016-10-18 08:48:25 +01:00
Andreas Kyrris 4a22fa0438 Use Probe's property to lookup loadbalancer_id. 2016-10-18 08:33:31 +01:00
Andreas Kyrris e63d120b57 Fix id of azurerm_lb_probe. 2016-10-18 08:33:31 +01:00
Andreas Kyrris a0ad874d25 Update test for azurerm_lb_nat_rule id. 2016-10-18 08:33:31 +01:00
Andreas Kyrris 4bf1985453 Update test for azurerm_lb_nat_pool id. 2016-10-18 08:33:31 +01:00
Andreas Kyrris f4980bf1b5 Update test for azurerm_lb_rule id. 2016-10-18 08:33:31 +01:00
Andreas Kyrris c1d4397673 Update test for azurerm_lb_probe id. 2016-10-18 08:33:31 +01:00
Andreas Kyrris 25794f6692 Update test for azurerm_lb_backend_address_pool id. 2016-10-18 08:33:31 +01:00
Matt Moyer 2b9f5f5f6f Add support for AWS US East (Ohio) region. 2016-10-17 15:48:18 -05:00
Peter McAtominey 89b49f809b provider/azurerm: add account_kind and access_tier to storage_account resource
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMStorageAccount -timeout 120m
=== RUN   TestAccAzureRMStorageAccount_importBasic
--- PASS: TestAccAzureRMStorageAccount_importBasic (140.06s)
=== RUN   TestAccAzureRMStorageAccount_basic
--- PASS: TestAccAzureRMStorageAccount_basic (155.43s)
=== RUN   TestAccAzureRMStorageAccount_disappears
--- PASS: TestAccAzureRMStorageAccount_disappears (134.99s)
=== RUN   TestAccAzureRMStorageAccount_blobEncryption
--- PASS: TestAccAzureRMStorageAccount_blobEncryption (161.59s)
=== RUN   TestAccAzureRMStorageAccount_blobStorageWithUpdate
--- PASS: TestAccAzureRMStorageAccount_blobStorageWithUpdate (131.49s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	723.694s
2016-10-17 17:49:07 +01:00
James Bardin 7478b7a914 Merge pull request #9369 from hashicorp/jbardin/TestBuildEC2AttributeFilterList
Make buildEC2AttributeFilterList output sorted
2016-10-17 12:34:34 -04:00
Tom Wilkie 08c5d2a939 Read back aws_launch_configuration's associate_public_ip_address field, to enable importing. 2016-10-17 09:12:25 -05:00
@tmshn 8ec06e82b6 Added "arn" attribute to AWS Lambda alias 2016-10-16 21:43:44 +09:00
Raphael Randschau fc4c848778
provider/scaleway: add importer support 2016-10-15 23:49:14 +02:00
Raphael Randschau 903170ddf3
provider/scaleway: add image data source 2016-10-15 19:32:08 +02:00
Raphael Randschau 1552c33033
provider/scaleway: add bootscript data source
bootscripts allow you to start Scaleway servers with a specific kernel version.
The `scaleway_server`  has always had a bootscript parameter, and the
`scaleway_bootscript` datasource allows you to lookup bootscripts to be used in
conjunction with the `scaleway_server` resource.
2016-10-15 19:32:01 +02:00
James Nugent f19990a0b3 Merge pull request #9370 from hashicorp/b-crash-8609
provider/google: Ensure we don't assert on nil
2016-10-14 15:13:53 -05:00
James Nugent 0459d86b93 provider/google: Ensure we don't assert on nil
This commit tests whether an interface is nil before type asserting it
to string - this should fix the panic reported in #8609.

We also clean up the schema definition to the newer style without
redundant type declarations.
2016-10-14 12:19:46 -05:00
James Bardin 7d0ed45ec9 Make buildEC2AttributeFilterList output sorted
Makes the output deterministic
2016-10-14 12:22:45 -04:00
Clint 46ee2ef51a Merge pull request #6819 from hashicorp/f-aws-vpc-data-sources
provider/aws: data sources for AWS network planning
2016-10-13 14:17:55 -05:00
Sharif Nassar 84d943fc82 Allow empty route_table_ids in aws_vpc_endpoint 2016-10-13 10:41:38 -07:00
Clint 04b7950e15 Merge pull request #9346 from hashicorp/b-aws-vpn-connection-retry
provider/aws: Poll to confirm delete of resource_aws_customer_gateway
2016-10-13 11:22:43 -05:00
Martin Atkins ad314118a6 Merge #9327: github_repository resource 2016-10-13 08:15:37 -07:00
Martin Atkins f4ecf72125 provider/github: github_repository resource
Allows creation of repositories within the organization configured on the
provider.
2016-10-13 08:04:17 -07:00
clint shryock b2b886db43 provider/aws: Poll to confirm delete of resource_aws_customer_gateway 2016-10-12 17:41:03 -05:00
Modestas Vainius 7385fa9eac provider/aws: Support refresh of EC2 instance user_data.
Make sure to hash base64 decoded value since user_data might be given
either raw bytes or base64 value.

This helps https://github.com/hashicorp/terraform/issues/1887 somewhat
as now you can:

1) Update user_data in AWS console.
2) Respectively update user_data in terraform code.
3) Just refresh terraform state and it should not report any changes.
2016-10-12 15:19:25 -05:00
clint shryock 77d76a69ba provider/aws: Bump Directory Service creation timeout to 45m 2016-10-12 09:47:39 -05:00
Carlos Sanchez ed37eae52b [AWS] Retry setTags operation 2016-10-11 15:38:25 -05:00
Justin Nauman be523d3792 Fixes #6076 - Adjusts check to allow for instance-id reset on aws_route 2016-10-11 15:35:03 -05:00
Herkermer Sherwood e81d06d505 Remove If-Match check and update ETag in state based on HeadObject
Fixes #4805
2016-10-11 11:43:33 -05:00
James Nugent ad57b445e9 Merge pull request #9273 from jmcarp/issue-5307
Parse AWS partition from ARN.
2016-10-11 11:31:04 -05:00
Kazunori Kojima dd2e9a5caa provider/aws: Fix cause error when re-apply specified together `etag` and `kms_key_id` 2016-10-11 11:11:30 -05:00
Krzysztof Wilczynski 6393ad743f Add missing unit test and re-factor for clarity.
This commit adds a missing unit test for the API Gateway integration type
attribute validation helper, plus changes the way how value is inspected
to a simple lookup table. Additionally, changes the wording of the error
message, and adds invalid test cases to the HTTP method validation helper.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-11 08:17:05 -05:00
Eric Nieuwenhuijsen 3e651a7130 provider/azurerm: Implement azurerm_storage_share 2016-10-11 11:41:21 +02:00
James Nugent 276ff83b84 Merge pull request #9312 from nicolai86/chore/upgrade-scaleway-api
provider/scaleway: SDK upgrade
2016-10-10 22:44:15 -04:00
James Nugent f1503d3b39 Merge pull request #9305 from BedeGaming/azurerm-lb-rule-validation
provider/azurerm: fix loadbanacer_rule tests failing validation
2016-10-10 22:42:56 -04:00
James Nugent 51c4f8665f Merge pull request #9306 from BedeGaming/azurerm-cdn-profile-id-fix
provider/azurerm: fix cdn_profile ID parsing, add import capability
2016-10-10 20:33:50 -04:00
James Nugent 52f4e23ac3 provider/aws: Add extra logging on AuthFailure
This pull request is intended to add a temporary control to Terraform to
output more verbose logging in the case of an AuthFailure error being
returned by the AWS API.
2016-10-10 17:26:30 -04:00
Raphael Randschau d98e5200cc
provider/scaleway: expose Region as user facing configuration 2016-10-10 20:02:32 +02:00
Raphael Randschau a5d105da36
provider/scaleway: use building DetachIP func 2016-10-10 20:02:10 +02:00
Joel Vasallo 7dd376216b Added documentation around access_logs enabled and reverted default
value to true
2016-10-10 10:05:13 -05:00
Joel Vasallo f290a3a955 ALB: Enabled s3.enabled and changed default value of s3.enabled
- Disabled access logs by default
- Enabled case to set value of s3.enabled
2016-10-10 09:46:28 -05:00
Peter McAtominey a07275df5e provider/azurerm: fix computed tags causing non-empty plan
The tag schema was changed in #9199, setting the Computed flag, this was causing
the plan to not be empty for resources which support tags but none were set, as
no value would be set by flattenAndSetTags.

Setting an empty map instead fixes the issue, ran original failing test and an
update tags test to ensure nothing else was broken.

Depends on #9305.

```
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMCdnProfile -timeout 120m
=== RUN   TestAccAzureRMCdnProfile_importWithTags
--- PASS: TestAccAzureRMCdnProfile_importWithTags (171.64s)
=== RUN   TestAccAzureRMCdnProfile_basic
--- PASS: TestAccAzureRMCdnProfile_basic (162.70s)
=== RUN   TestAccAzureRMCdnProfile_withTags
--- PASS: TestAccAzureRMCdnProfile_withTags (203.12s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	537.538s
```
2016-10-10 14:19:20 +01:00
Peter McAtominey d60b9ab018 provider/azurerm: fix cdn_profile ID parsing, add import capability
cdn_profile resource was using `Profiles` instead of `profiles` to gather the
name in the read and delete methods, added importing capability with test to
confirm read now works as expected.

```
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMCdnProfile -timeout 120m
=== RUN   TestAccAzureRMCdnProfile_importWithTags
--- PASS: TestAccAzureRMCdnProfile_importWithTags (170.00s)
=== RUN   TestAccAzureRMCdnProfile_basic
--- PASS: TestAccAzureRMCdnProfile_basic (166.33s)
=== RUN   TestAccAzureRMCdnProfile_withTags
--- PASS: TestAccAzureRMCdnProfile_withTags (185.94s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	522.333s
```
2016-10-10 14:03:48 +01:00
Peter McAtominey c4963dd66e provider/azurerm: fix loadbanacer_rule tests failing validation
TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMLoadBalancerRule -timeout 120m
=== RUN   TestAccAzureRMLoadBalancerRule_basic
--- PASS: TestAccAzureRMLoadBalancerRule_basic (149.43s)
=== RUN   TestAccAzureRMLoadBalancerRule_removal
--- PASS: TestAccAzureRMLoadBalancerRule_removal (165.38s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	314.894s
2016-10-10 10:16:16 +01:00
Joel Vasallo 16c1366e63 Reverted alb false logic to be a string instead of converted bool to
string
2016-10-09 22:09:41 -05:00
Krzysztof Wilczynski 70a90cc1f4 Handle EC2 tags related errors in CloudFront Distribution resource. (#9298)
This commits changes the behaviour in a case there was an error while
interacting with EC2 tags related to the CloudFormation Distribution
resource, fixing the issue with nil pointer dereference when despite
an error being present code path to handle tags was executed.

Also, a small re-factor of the `validateHTTP` helper method,
and a unit test added for it.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-09 20:51:16 +02:00
Joshua Carp a8e68ab25e Add partition to remaining ARN builders. 2016-10-08 00:52:50 -04:00
Joel Vasallo e00b2448d8 Fixed alb access_log enabled type to match that of aws-sdk-go 2016-10-07 19:32:19 -05:00
Joel Vasallo a4743eac33 Enable/Disable option for ALB Access Logs 2016-10-07 18:41:54 -05:00
Paul Stack 89138fe22b Merge pull request #9122 from hashicorp/b-arm-vm-diagnostics
provider/azurerm: arm_virtual_machine diagnostics_profile was causing a panic on the Read func
2016-10-07 19:42:15 +01:00
stack72 dcfdc6ab30
provider/azurerm: arm_virtual_machine diagnostics_profile was causing a
panic on the Read func

Fixes #8995

The Diagnostics profile was a badly laid out resource. All we needed to
set was whether it was enabled and the storage account to save the logs
to. The old schema parameter was deprecated and replaced with a much
simplier structure

```
% make testacc TEST=./builtin/providers/azurerm TESTARGS='-run=TestAccAzureRMVirtualMachine_diagnosticsProfile'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/09/29 12:21:04 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/azurerm -v
-run=TestAccAzureRMVirtualMachine_diagnosticsProfile -timeout 120m
=== RUN   TestAccAzureRMVirtualMachine_diagnosticsProfile
--- PASS: TestAccAzureRMVirtualMachine_diagnosticsProfile (1066.76s)
PASS
ok
github.com/hashicorp/terraform/builtin/providers/azurerm1066.776s
```
2016-10-07 19:36:45 +01:00
Paul Stack a085c8d71e provider/azurerm: Add Load Balancer resources (#9199)
* provider/azurerm: Add AzureRM Loadbalancer resource

Adds support for the elusive Azure LoadBalancer

* [x] `azurerm_lb`
* [x] `azurerm_lb_backend_address_pool`
* [x] `azurerm_lb_rule`
* [x] `azurerm_lb_nat_rule`
* [x] `azurerm_lb_probe`
* [x] `azurerm_lb_nat_pool`

Test Results:

```
make testacc TEST=./builtin/providers/azurerm TESTARGS='-run=TestAccAzureRMLoadbalancer'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
TF_ACC=1 go test ./builtin/providers/azurerm -v
-run=TestAccAzureRMLoadbalancer -timeout 120m
=== RUN   TestAccAzureRMLoadbalancerBackEndAddressPool_basic
--- PASS: TestAccAzureRMLoadbalancerBackEndAddressPool_basic (207.26s)
=== RUN   TestAccAzureRMLoadbalancerBackEndAddressPool_removal
--- PASS: TestAccAzureRMLoadbalancerBackEndAddressPool_removal (165.89s)
=== RUN   TestAccAzureRMLoadbalancerNatRule_basic
--- PASS: TestAccAzureRMLoadbalancerNatRule_basic (179.30s)
=== RUN   TestAccAzureRMLoadbalancerNatRule_removal
--- PASS: TestAccAzureRMLoadbalancerNatRule_removal (180.73s)
=== RUN   TestAccAzureRMLoadbalancerRule_basic
--- PASS: TestAccAzureRMLoadbalancerRule_basic (170.40s)
=== RUN   TestAccAzureRMLoadbalancerRule_removal
--- PASS: TestAccAzureRMLoadbalancerRule_removal (204.23s)
=== RUN   TestAccAzureRMLoadbalancer_basic
--- PASS: TestAccAzureRMLoadbalancer_basic (136.03s)
=== RUN   TestAccAzureRMLoadbalancer_frontEndConfig
--- PASS: TestAccAzureRMLoadbalancer_frontEndConfig (214.47s)
=== RUN   TestAccAzureRMLoadbalancer_tags
--- PASS: TestAccAzureRMLoadbalancer_tags (215.52s)
=== RUN   TestAccAzureRMLoadbalancerProbe_basic
--- PASS: TestAccAzureRMLoadbalancerProbe_basic (183.36s)
=== RUN   TestAccAzureRMLoadbalancerProbe_removal
--- PASS: TestAccAzureRMLoadbalancerProbe_removal (185.86s)
=== RUN   TestAccAzureRMLoadbalancerNatPool_basic
--- PASS: TestAccAzureRMLoadbalancerNatPool_basic (161.47s)
=== RUN   TestAccAzureRMLoadbalancerNatPool_removal
--- PASS: TestAccAzureRMLoadbalancerNatPool_removal (167.38s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/azurerm
1673.852s
```

* provider/azurerm: Documentation for the ARM LB resources
2016-10-07 14:14:26 -04:00
Paul Stack 181fd25ee4 Merge pull request #9009 from hashicorp/tests-aws-import-eip
provider/aws: Add some tests for the Import for aws_eip
2016-10-07 16:25:41 +01:00
stack72 5479e178b9
provider/aws: Add some tests for the Import for aws_eip
The Read func of the EIP has changed to set the `vpc` boolean value on
the response object having an Address. This is required as an EIP that
was specified, without a domain and then imported, would cause a
perpetual plan.

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEIP_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/09/23 09:28:32 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEIP_ -timeout
120m
=== RUN   TestAccAWSEIP_importEc2Classic
--- PASS: TestAccAWSEIP_importEc2Classic (116.16s)
=== RUN   TestAccAWSEIP_importVpc
--- PASS: TestAccAWSEIP_importVpc (61.89s)
=== RUN   TestAccAWSEIP_basic
--- PASS: TestAccAWSEIP_basic (18.86s)
=== RUN   TestAccAWSEIP_instance
--- PASS: TestAccAWSEIP_instance (185.95s)
=== RUN   TestAccAWSEIP_network_interface
--- PASS: TestAccAWSEIP_network_interface (63.20s)
=== RUN   TestAccAWSEIP_twoEIPsOneNetworkInterface
--- PASS: TestAccAWSEIP_twoEIPsOneNetworkInterface (65.64s)
=== RUN   TestAccAWSEIP_associated_user_private_ip
--- PASS: TestAccAWSEIP_associated_user_private_ip (201.34s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    713.072s
```
2016-10-07 16:21:11 +01:00
Paul Stack 4ac7d0a6bb Merge pull request #8103 from BedeGaming/validation-helper
helper: create validation package to provide common validation functions
2016-10-07 13:42:29 +01:00
Paul Stack dd66af0fa0 Merge pull request #8701 from steveh/feature/aws-billing-service-account
provider/aws: Add AWS Billing & Cost Management service account
2016-10-07 13:34:51 +01:00
Paul Stack 250be11fdd Merge pull request #9073 from carinadigital/GH-9072
provider/azurerm: set resource_group_name on resource import
2016-10-07 13:29:08 +01:00
Paul Stack 1b2f553d52 Merge pull request #9277 from kwilczynski/fix/return-correct-image-data_source_aws_ami
provider/aws: Fix. Return correct AMI image when `most_recent` is set to `true`.
2016-10-07 12:26:29 +01:00
Krzysztof Wilczynski 664c788b26
Fix. Return correct AMI image when `most_recent` is set to `true`.
This commit resolves a regression introduced in #9033 that caused an
unfiltered image to be returned despite a search criteria being set
accordingly.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-07 12:05:54 +01:00
DJ Home 56f35dd67d
Add ability to import AWS OpsWorks Custom Layers 2016-10-07 11:57:11 +01:00
Joshua Carp 1f8c2e4c69 Parse AWS partition from ARN.
[Resolves #5307]
2016-10-07 00:08:30 -04:00
Paul Stack 7bab7f44cb Merge pull request #9228 from alphagov/datadog_dashboard_type_style
Datadog dashboard "type" and "style" options
2016-10-06 23:24:57 +01:00
Peter McAtominey 0cb6e7df8b provider/azurerm: add enable_blob_encryption to storage_account resource
This allows Storage Service Encryption to be enabled.

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMStorageAccount -timeout 120m
=== RUN   TestAccAzureRMStorageAccount_importBasic
--- PASS: TestAccAzureRMStorageAccount_importBasic (139.00s)
=== RUN   TestAccAzureRMStorageAccount_basic
--- PASS: TestAccAzureRMStorageAccount_basic (151.03s)
=== RUN   TestAccAzureRMStorageAccount_blobEncryption
--- PASS: TestAccAzureRMStorageAccount_blobEncryption (149.94s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	440.051s
2016-10-06 22:50:02 +01:00
Paul Stack 97ad032474 Merge pull request #8859 from carinadigital/arm-vm-fix
provider/azurerm: Terraform Plan errors when created resources disappear
2016-10-06 22:38:30 +01:00
Paul Stack e012c4fcc5 Merge pull request #9242 from BedeGaming/azurerm-sb-namespace-keys
provider/azurerm: expose default keys for servicebus_namespace
2016-10-06 21:53:23 +01:00
Krzysztof Wilczynski 1260b3a9b5
Add new "ANY" as valid HTTP method to API Gateway validator.
This commit adds a new HTTP method to a list of valid HTTP methods which
is now accepted by API Gateway.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
2016-10-06 16:11:45 +01:00
Peter McAtominey f733d6aa8a provider/azurerm: expose default keys for servicebus_namespace
A default authorization rule is created by Azure which, if present is exported by
the resource.

TF_ACC=1 go test ./builtin/providers/azurerm -v -run TestAccAzureRMServiceBusNamespace -timeout 120m
=== RUN   TestAccAzureRMServiceBusNamespaceCapacity_validation
--- PASS: TestAccAzureRMServiceBusNamespaceCapacity_validation (0.00s)
=== RUN   TestAccAzureRMServiceBusNamespaceSku_validation
--- PASS: TestAccAzureRMServiceBusNamespaceSku_validation (0.00s)
=== RUN   TestAccAzureRMServiceBusNamespace_basic
--- PASS: TestAccAzureRMServiceBusNamespace_basic (352.03s)
=== RUN   TestAccAzureRMServiceBusNamespace_readDefaultKeys
--- PASS: TestAccAzureRMServiceBusNamespace_readDefaultKeys (349.17s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/azurerm	701.278s
2016-10-05 22:12:28 +01:00
clint shryock dad6face2b re-go-fmt after rebase
use us-west-2 region in tests

update test with working config

provider/aws: Update EMR contribution with passing test, polling for instance in DELETE method

remove defaulted role

document emr_cluster

rename aws_emr -> aws_emr_cluster

update docs for name change

update delete timeout/polling

rename emr taskgroup to emr instance group

default instance group count to 0, down from 60

update to ref emr_cluster, emr_instance_group

more cleanups for instance groups; need to read and update

add read, delete method for instance groups

refactor the read method to seperate out the fetching of the specific group

more refactoring for finding instance groups

update emr instance group docs

err check on reading HTTP. Dont' return the error, just log it

refactor the create method to catch optionals

additional cleanups, added a read method

update test to be non-master-only

wrap up the READ method for clusters

poll for instance group to be running after a modification

patch up a possible deref

provider/aws: EMR cleanups

fix test naming

remove outdated docs

randomize emr_profile names
2016-10-05 14:30:16 -05:00
Brian Chen ad8679e916 basic emr implementation
quick emr resize implementation

ass task group

not force new

add task group

check empty slices

clean up

rename to initial_instance_count

add task instance group as resource

cluster resize core group

clean up

add name option

log info

clean up

change log debug format

clean up

add missing security groups for master and slave

add bootstrap actions

add options for bootstrap action

add tags option

clean up

fix for tags array

support delimiters : =

bootstrap actions fix

add configurations item

load local or remote config

rename function

support multiple bootstrap actions

default value 0 for core group

follow aws api able to create a master only

tags use terraform tag schema

option item for log_uri

ec2_attribute as option

add emr task group accTests

add embedded json config

add embedded json config

add service_role and instance_profile

add partial state support for either the "TERMINATED" or "TERMINATED_WITH_ERRORS" state

not allowing to change name or instance_type for task group

"core_instance_type" change into "Optional" and  "Computed"

apply MaxItems for ec2Attributes

remove all debug "fmt.Println"

clean up debug info and useless variable

Expose visible_to_all_users as an option, default will be true

remove debug info

logging should happen before setId("")

add hanChange checking first

clean up debug log

add some force new

double check the core group existed

add waiting and polling, until cluster up

testcase add EMR cluster id and status checking

clean up using common way to read ec2_attributes
2016-10-05 14:30:16 -05:00
Paul Stack 5192c7d14c Merge pull request #9196 from hashicorp/arm-sql-datawarehouse
provider/azurerm: Support AzureRM Sql Database DataWarehouse
2016-10-05 20:19:17 +01:00
clint shryock 5b87cd49a9 provider/aws: Update EFS resource to read performance mode and creation_token 2016-10-05 13:48:35 -05:00
Clint e2c74fce7f Merge pull request #9230 from lifesum/route53_healthcheck
provider/aws - Add update support for `search_string` in aws_cloudwatch_metric_alarm
2016-10-05 08:52:34 -05:00
Alexander Hellbom f6c66025cc Add update support for `search_string` 2016-10-05 13:25:00 +02:00
Colin Saliceti cae5d8bbb9 Add type and styles to datadog timeboard graphs
Create the resources for title and styles and add them to the acceptance
test. Styles currently only support "palette".
2016-10-05 09:44:54 +01:00
Colin Saliceti b53d7a7b49 Use new Datadog GraphDefinitionRequest struct
This new struct avoids requiring to repeat the struct definition in this
code here. It avoids duplication and makes it more flexible so more
options can be added to the struct without breaking the code here.
2016-10-05 09:44:54 +01:00
Sam Dunne 792a6c0232
Remove unused dependency 2016-10-05 09:32:10 +01:00
Paul Stack aa97ebd0e7 Merge pull request #9220 from AMeng/import-db-event-sub
provider/aws: Import aws_db_event_subscription
2016-10-05 01:03:53 +01:00
AMeng b7fae4028c provider/aws: Import aws_db_event_subscription 2016-10-04 15:24:30 -06:00
Michael Henry ad8bff98bb Extract integration type validator 2016-10-04 12:51:18 -04:00
Michael Henry 71b62d83b2 Allow new aws api-gateway integration types
The added types are 'AWS_PROXY' for integrating with lambdas and
'HTTP_PROXY' for integrating via http.

See http://docs.aws.amazon.com/apigateway/api-reference/resource/integration/
2016-10-04 12:23:04 -04:00
Sam Dunne d073a90cb1
Create provisioner for postgresql extensions
This change adds support for installing postgresql extensions on a
postgresql server.
2016-10-04 16:32:28 +01:00