Commit Graph

20 Commits

Author SHA1 Message Date
Sander van Harmelen d97b24e3c1
Add tests and fix last issues 2016-05-26 19:56:03 -05:00
Sander van Harmelen 8560f50cbc
Change taint behaviour to act as a normal resource
This means it’s shown correctly in a plan and takes into account any
actions that are dependant on the tainted resource and, vice verse, any
actions that the tainted resource depends on.

So this changes the behaviour from saying this resource is tainted so
just forget about it and make sure it gets deleted in the background,
to saying I want that resource to be recreated (taking into account the
existing resource and it’s place in the graph).
2016-05-26 19:55:26 -05:00
Matt Good 21b0a03d70 Support for multiple providers of the same type
Adds an "alias" field to the provider which allows creating multiple instances
of a provider under different names. This provides support for configurations
such as multiple AWS providers for different regions. In each resource, the
provider can be set with the "provider" field.

(thanks to Cisco Cloud for their support)
2015-04-20 14:14:34 -07:00
Paul Hinze f1c9e32fa0 core: tweaks from code review 2015-03-05 10:11:14 -06:00
Paul Hinze 6e13aacefa core: [refactor] DRY up EvalWriteState nodes
Also some final comment cleanup
2015-03-04 18:22:18 -06:00
Paul Hinze 6c93fbb85d core: [refactor] store Deposed resource instances as a list
Deposed instances need to be stored as a list for certain pathological
cases where destroys fail for some reason (e.g. upstream API failure,
Terraform interrupted mid-run). Terraform needs to be able to remember
all Deposed nodes so that it can clean them up properly in subsequent
runs.

Deposed instances will now never touch the Tainted list - they're fully
managed from within their own list.

Added a "multiDepose" test case that walks through a scenario to
exercise this.
2015-03-04 12:25:59 -06:00
Paul Hinze 426f253085 core: [refactor] split WriteState EvalNodes
This is the non-DRY pass.
2015-03-04 12:25:47 -06:00
Paul Hinze d81ec2d37e core: [refactor] pull out common ReadState behavior 2015-03-04 12:25:47 -06:00
Paul Hinze 596e891b80 core: [refactor] pull Deposed out of Tainted list 2015-03-04 12:25:47 -06:00
Mitchell Hashimoto 6affc57b2d terraform: destroy node should not create 2015-02-24 22:45:47 -08:00
Mitchell Hashimoto 429711b938 terraform: PostStateUpdate hook and EvalUpdateStateHook 2015-02-23 19:09:48 -08:00
Mitchell Hashimoto b52881d232 terraform: clean up EvalNodes 2015-02-19 12:08:32 -08:00
Mitchell Hashimoto 7b305d1f41 terraform: forgot the docs :( 2015-02-19 12:08:08 -08:00
Mitchell Hashimoto c8091aa338 terraform: fix more create-before-destroy state juggling 2015-02-19 12:08:07 -08:00
Mitchell Hashimoto 33cad6d207 terraform: fix create before destroy edge case with partial state 2015-02-19 12:08:07 -08:00
Mitchell Hashimoto f7f1f17b49 terraform: create before destroy 2015-02-19 12:08:07 -08:00
Mitchell Hashimoto 819aed67d4 terraform: provisioners 2015-02-19 12:08:06 -08:00
Mitchell Hashimoto 93f3050dbd terraform: make things more linear 2015-02-19 12:08:04 -08:00
Mitchell Hashimoto 2680b6bed4 terraform: refresh tainted resources 2015-02-19 12:08:00 -08:00
Mitchell Hashimoto 1e962b868d terraform: Refresh, Read/Write state 2015-02-19 12:08:00 -08:00