Commit Graph

16385 Commits

Author SHA1 Message Date
Seth Vargo 5d79395354
Add a prefix option to random_id provider 2017-02-16 11:08:17 -05:00
Jake Champlin 555c8bb723 Merge pull request #12011 from hashicorp/f-fix-role-regexp
provider/aws: Fix matching regexp in invalid role config test
2017-02-16 10:32:00 -05:00
Jake Champlin 18bb3aade3 Merge pull request #11993 from hashicorp/b-fix-cloudflare-validator
provider/cloudflare: Fix record validation
2017-02-16 10:15:46 -05:00
Jake Champlin c85a874e16
provider/aws: Fix matching regexp in invalid role config test
```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSRole_badJSON'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/16 10:08:07 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSRole_badJSON -timeout 120m
=== RUN   TestAccAWSRole_badJSON
--- PASS: TestAccAWSRole_badJSON (0.00s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    0.011s
```
2017-02-16 10:14:25 -05:00
Paul Stack 546b424d7d provider/aws: Allow aws_instances to be resized rather than forcing a (#11998)
new instance

Fixes: #9157

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSInstance_changeInstanceType'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/16 15:13:21 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSInstance_changeInstanceType -timeout 120m
=== RUN   TestAccAWSInstance_changeInstanceType
--- PASS: TestAccAWSInstance_changeInstanceType (303.85s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	303.876s
```
2017-02-16 16:43:09 +02:00
Paul Stack f81616d292 provider/statuscake: Fixing up the StatusCake acceptance tests (#12006)
```
% make testacc TEST=./builtin/providers/statuscake                                                      2 ↵ ✹
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/16 15:30:40 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/statuscake -v  -timeout 120m
=== RUN   TestProvider
--- PASS: TestProvider (0.00s)
=== RUN   TestProvider_impl
--- PASS: TestProvider_impl (0.00s)
=== RUN   TestAccStatusCake_basic
--- PASS: TestAccStatusCake_basic (2.14s)
=== RUN   TestAccStatusCake_tcp
--- PASS: TestAccStatusCake_tcp (1.66s)
=== RUN   TestAccStatusCake_withUpdate
--- PASS: TestAccStatusCake_withUpdate (3.62s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/statuscake	7.435s
```
2017-02-16 16:20:23 +02:00
Jake Champlin e052ded267
add missing return 2017-02-16 07:57:34 -05:00
Paul Stack dae4282cf6 Update CHANGELOG.md 2017-02-16 14:23:16 +02:00
lstolyarov 3f3884890a making the sql admin password sensitive (#12004) 2017-02-16 12:16:00 +00:00
Jason Costello 5c8e86be09 optimize docs type (#11983) 2017-02-16 05:25:25 +00:00
Jake Champlin 125641e2bd provider/aws: Fix asg lifecycle hook test (#11995)
Fixes the `TestAccAWSAutoscalingLifecycleHook_omitDefaultResult` acceptance test to run in parallel.

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAutoscalingLifecycleHook_omitDefaultResult'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/15 22:33:26 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAutoscalingLifecycleHook_omitDefaultResult -timeout 120m
=== RUN   TestAccAWSAutoscalingLifecycleHook_omitDefaultResult
--- PASS: TestAccAWSAutoscalingLifecycleHook_omitDefaultResult (146.91s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    146.917s
```
2017-02-16 05:22:12 +00:00
Jake Champlin 3219037359 provider/aws: Fix sg data source acctests (#11994)
Fixes the `data_source_aws_security_group` acceptance tests

```
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccDataSourceAwsSecurityGroup'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/15 22:19:51 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccDataSourceAwsSecurityGroup -timeout 120m
=== RUN   TestAccDataSourceAwsSecurityGroup
--- PASS: TestAccDataSourceAwsSecurityGroup (45.67s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    45.676s
```
2017-02-16 05:21:56 +00:00
Jake Champlin 179aa62ad4
provider/cloudflare: Fix record validation
Previously we only validated that the cloudflare record provided was a valid record type. However, a record can be of a valid type, and still not be proxied, making it an invalid record type.

The main downside to having to check for whether or not the record type is proxied or not during validation, is that it relies on having two schema keys populated. This means that we can only catch the improper record type during `apply` time, instead of `plan` time.

```
$ go test -v -run "TestValidateRecordType" ./builtin/providers/cloudflare
=== RUN   TestValidateRecordType
--- PASS: TestValidateRecordType (0.00s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/cloudflare     0.004s
```
2017-02-15 21:52:04 -05:00
Paul Stack ad69c540b8 provider/statuscake: Bump Statuscake SDK version (#11985) 2017-02-15 23:36:51 +00:00
Paul Stack e5f899d357 provider/statuscake: Add support for Port in statuscake_test (#11966)
Fixes: #11923

This required the upstream library to have a PR accepted
2017-02-15 23:29:05 +00:00
netjunki 508da1ec10 provider/aws: add bucket name to delete error notification (#11952)
* provider/aws: add bucket name to delete error notification

* cast Get; use %q instead of '%s'
2017-02-15 23:07:55 +00:00
stack72 ac30dec555
Update CHANGELOG.md 2017-02-15 23:05:31 +00:00
Paul Stack 97cf8f6543 provider/azurerm: Mark the azurerm_scale_set machine password as (#11982)
sensitive

This was pointed out at the HUG in London tonight that we save the plain
text password in state

I don't think this will be ported back to 0-8-stable
2017-02-15 23:03:55 +00:00
Laurens Vanderhoven 4940fd64f1 provider/azurerm: Remove location argument from azurerm_lb_* (#11969)
* provider/azurerm: Remove location argument from loadbalancer_backend_address_pool

Applying a Terraform execution plan containing a loadbalancer_backend_address_pool
with a location argument throws a warning:

----
Warnings:

  * azurerm_lb_backend_address_pool.test: "location": [DEPRECATED] location is no longer used

  No errors found. Continuing with 1 warning(s).
----

* provider/azurerm: Remove location argument from azurerm_lb_rule

(Similar to https://github.com/hashicorp/terraform/pull/11963)

Applying a Terraform execution plan containing a azurerm_lb_rule
with a location argument throws a warning:

```
Warnings:

  * azurerm_lb_rule.test: "location": [DEPRECATED] location is no longer used

No errors found. Continuing with 1 warning(s).
```

Removing the (required) location argument from the documentation
as it is deprecated as per the warning.

* provider/azurerm: Remove location argument from azurerm_lb_probe

(Similar to https://github.com/hashicorp/terraform/pull/11963)

Applying a Terraform execution plan containing a azurerm_lb_probe
with a location argument throws a warning:

```
Warnings:

  * azurerm_lb_probe.test: "location": [DEPRECATED] location is no longer used

No errors found. Continuing with 1 warning(s).
```

Removing the (required) location argument from the documentation
as it is deprecated as per the warning.
2017-02-15 23:00:35 +00:00
Paul Stack 69f397d5c9 provider/aws: Add support for AWS EBS Elastic Volumes (#11981)
This allows for updates to size, type and iops

Fixes: #11931

```
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSEBSVolume_update'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/02/15 22:35:43 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSEBSVolume_update -timeout 120m
=== RUN   TestAccAWSEBSVolume_updateSize
--- PASS: TestAccAWSEBSVolume_updateSize (53.57s)
=== RUN   TestAccAWSEBSVolume_updateType
--- PASS: TestAccAWSEBSVolume_updateType (57.53s)
=== RUN   TestAccAWSEBSVolume_updateIops
--- PASS: TestAccAWSEBSVolume_updateIops (53.63s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	164.753s
```
2017-02-15 22:54:32 +00:00
Martin Atkins 0138577313 Update CHANGELOG.md 2017-02-15 14:49:47 -08:00
Mitchell Hashimoto 1607c1187d release: clean up after v0.9.0-beta1 2017-02-15 22:39:57 +00:00
Mitchell Hashimoto 4e96da57ee
v0.9.0-beta1 2017-02-15 22:35:37 +00:00
Mitchell Hashimoto fa2fd0bf01 Merge pull request #11978 from hashicorp/b-state-locker
state/remote: export ClientLocker, test for implementation
2017-02-15 14:27:43 -08:00
Mitchell Hashimoto 03f6c650ca
state/remote: ClientLocker is just a Client that is a state.Locker 2017-02-15 14:27:02 -08:00
Mitchell Hashimoto 9451acc5da
state/remote: add unit test to verify s3 is a ClientLocker as well 2017-02-15 14:25:53 -08:00
Mitchell Hashimoto efe754183b
state/remote: export ClientLocker, test for implementation
This adds unit tests (that will fail at compile time) if various structs
don't implement the right interfaces for locking
2017-02-15 14:20:59 -08:00
James Bardin 6798cd5911 Merge pull request #11973 from hashicorp/jbardin/state-locking
Update state.Locker
2017-02-15 17:07:22 -05:00
James Bardin a372e9c54b fix state migration lock info 2017-02-15 17:00:54 -05:00
James Bardin 7c83819e78 Merge pull request #11974 from hashicorp/jbardin/azurerm-vet
Fix copied schema.Set values
2017-02-15 16:41:28 -05:00
Mitchell Hashimoto 7e14184393 Merge pull request #11976 from hashicorp/b-0-9-website
0.9 Website Content (Backends, Locking, etc.)
2017-02-15 13:15:52 -08:00
Mitchell Hashimoto 7394a066ec
website: document init and new state commands 2017-02-15 13:14:32 -08:00
Mitchell Hashimoto 22dd47c8af
website: document state locking and remote state page 2017-02-15 12:58:52 -08:00
Dana Hoffman 917e00f2ae Merge pull request #11631 from drebes/lts_fix
provider/google: make local_traffic_selector computed now that we rea…
2017-02-15 12:57:25 -08:00
Mitchell Hashimoto 03dca34161
website: document backend types 2017-02-15 12:19:38 -08:00
James Bardin cb2381b38c Fix copied schema.Set values
schema.Set contains a sync structure which can't be copied.
2017-02-15 15:03:40 -05:00
Mitchell Hashimoto 5f35c7964a Add 0.8.7 CHANGELOG entries 2017-02-15 11:46:53 -08:00
James Bardin ec00564be6 Clean up LockInfo and LockError and use them
Gove LockInfo a Marshal method for easy serialization, and a String
method for more readable output.

Have the state.Locker implementations use LockError when possible to
return LockInfo and an error.
2017-02-15 14:44:43 -05:00
James Bardin 888af93356 Have S3 check the lockID on Unlock
This needs to be improved to happen in a transaction, but it gets the
implementation passing the new tests.
2017-02-15 14:44:43 -05:00
James Bardin 67bbebce08 Have consul state reutrn the lock ID
The lock ID isn't used because the lock is tied to the client, but
return the lock ID to match the behavior of other locks.
2017-02-15 14:44:43 -05:00
James Bardin f2e496a14c Have backend operations properly unlock state
Make sure unlock is called with the correct LockID during operations
2017-02-15 14:41:55 -05:00
James Bardin 08cff7cc13 have LocalState check Lock ID on Unlock
Have LocalState store and check the lock ID, and strictly enforce
unlocking with the correct ID.

This isn't required for local lock correctness, as we track the file
descriptor to unlock, but it does provide a varification that locking
and unlocking is done correctly throughout terraform.
2017-02-15 14:41:55 -05:00
James Bardin 6aa1066f7c Store and use the correct IDs in TestRemoteLocks 2017-02-15 14:41:55 -05:00
James Bardin f5ed8cd288 Use NewLockInfo to get a pre-populated value
Using NewLockInfo ensure we start with all required fields filled.
2017-02-15 14:41:55 -05:00
James Bardin 52b2343672 make state test pass with new state.Locker 2017-02-15 14:41:55 -05:00
James Bardin 4f0c465187 make command tests pass with new state.Locker 2017-02-15 14:41:55 -05:00
James Bardin cd233fef6a make consul client pass state.Locker tests 2017-02-15 14:41:55 -05:00
James Bardin 67dc16c9ca Make backend/local test pass 2017-02-15 14:41:55 -05:00
James Bardin 6d32b70637 Make S3 remote state pass tests
TODO: update S3Client to make full use of the state.Locker interface
2017-02-15 14:41:55 -05:00
James Bardin 0ad6f08204 Make remote state test run
Make them compile against the new interface.
The tests will be updated later to check new behavior.
2017-02-15 14:41:55 -05:00