terraform/backend
James Bardin 928e60672f context Refresh and Apply sometimes return nil
The documentation for Refresh indicates that it will always return a
valid state, but that wasn't true in the case of a graph builder error.
While this same concept wasn't documented for Apply, it was still
assumed in the terraform apply code.

Since the helper testing framework relies on the absence of a state to
determine if it can call Destroy, the Context can't can't start
returning a state in all cases. Document this, and use the State method
to fetch the correct state value after Apply.

Add a nil check to the WriteState function, so that writing a nil state
is a noop.

Make sure to init before sorting the state, to make sure we're not
attempting to sort nil values. This isn't technically needed with the
current code, but it's just safer in general.
2017-04-14 14:56:10 -04:00
..
atlas backend/atlas: accept ATLAS_ADDRESS env var for address 2017-03-16 23:04:07 -07:00
init convert S3 remote state to a backend 2017-03-22 10:59:37 -04:00
legacy Make backcend/legacy match new Backend iface 2017-02-28 16:35:45 -05:00
local context Refresh and Apply sometimes return nil 2017-04-14 14:56:10 -04:00
remote-state only list environments when the keyName matches 2017-04-12 13:57:22 -04:00
backend.go provide contexts to clistate.Lock calls 2017-04-01 17:09:20 -04:00
cli.go command: use backend.CLIIinit 2017-02-28 10:58:29 -08:00
nil.go Update Backend interface to latest iteration 2017-02-28 16:07:07 -05:00
nil_test.go backend: introduce the backend set of interfaces 2017-01-26 14:33:49 -08:00
operation_type.go backend: introduce the backend set of interfaces 2017-01-26 14:33:49 -08:00
operationtype_string.go Update stringer-generated files to new boilerplate 2017-03-29 08:07:06 -07:00
testing.go test for proper state persistence 2017-03-23 10:06:07 -04:00