command/jsonplan: "deposed" should be a string, not a bool. (#20351)
This commit is contained in:
parent
818b4ec068
commit
c59a274e96
|
@ -242,7 +242,9 @@ func (p *plan) marshalResourceChanges(changes *plans.Changes, schemas *terraform
|
||||||
AfterUnknown: a,
|
AfterUnknown: a,
|
||||||
}
|
}
|
||||||
|
|
||||||
r.Deposed = rc.DeposedKey == states.NotDeposed
|
if rc.DeposedKey != states.NotDeposed {
|
||||||
|
r.Deposed = rc.DeposedKey.String()
|
||||||
|
}
|
||||||
|
|
||||||
key := addr.Resource.Key
|
key := addr.Resource.Key
|
||||||
if key != nil {
|
if key != nil {
|
||||||
|
|
|
@ -56,7 +56,7 @@ type resourceChange struct {
|
||||||
// "deposed", if set, indicates that this action applies to a "deposed"
|
// "deposed", if set, indicates that this action applies to a "deposed"
|
||||||
// object of the given instance rather than to its "current" object. Omitted
|
// object of the given instance rather than to its "current" object. Omitted
|
||||||
// for changes to the current object.
|
// for changes to the current object.
|
||||||
Deposed bool `json:"deposed,omitempty"`
|
Deposed string `json:"deposed,omitempty"`
|
||||||
|
|
||||||
// Change describes the change that will be made to this object
|
// Change describes the change that will be made to this object
|
||||||
Change change `json:"change,omitempty"`
|
Change change `json:"change,omitempty"`
|
||||||
|
|
|
@ -60,7 +60,6 @@
|
||||||
"mode": "managed",
|
"mode": "managed",
|
||||||
"type": "test_instance",
|
"type": "test_instance",
|
||||||
"name": "test",
|
"name": "test",
|
||||||
"deposed": true,
|
|
||||||
"change": {
|
"change": {
|
||||||
"actions": [
|
"actions": [
|
||||||
"create"
|
"create"
|
||||||
|
@ -81,7 +80,6 @@
|
||||||
"mode": "managed",
|
"mode": "managed",
|
||||||
"type": "test_instance",
|
"type": "test_instance",
|
||||||
"name": "test",
|
"name": "test",
|
||||||
"deposed": true,
|
|
||||||
"change": {
|
"change": {
|
||||||
"actions": [
|
"actions": [
|
||||||
"create"
|
"create"
|
||||||
|
@ -102,7 +100,6 @@
|
||||||
"mode": "managed",
|
"mode": "managed",
|
||||||
"type": "test_instance",
|
"type": "test_instance",
|
||||||
"name": "test",
|
"name": "test",
|
||||||
"deposed": true,
|
|
||||||
"change": {
|
"change": {
|
||||||
"actions": [
|
"actions": [
|
||||||
"create"
|
"create"
|
||||||
|
|
|
@ -35,7 +35,6 @@
|
||||||
"mode": "managed",
|
"mode": "managed",
|
||||||
"type": "test_instance",
|
"type": "test_instance",
|
||||||
"name": "test",
|
"name": "test",
|
||||||
"deposed": true,
|
|
||||||
"change": {
|
"change": {
|
||||||
"actions": [
|
"actions": [
|
||||||
"update"
|
"update"
|
||||||
|
@ -59,7 +58,6 @@
|
||||||
"mode": "managed",
|
"mode": "managed",
|
||||||
"type": "test_instance",
|
"type": "test_instance",
|
||||||
"name": "test-delete",
|
"name": "test-delete",
|
||||||
"deposed": true,
|
|
||||||
"change": {
|
"change": {
|
||||||
"actions": [
|
"actions": [
|
||||||
"delete"
|
"delete"
|
||||||
|
|
|
@ -35,7 +35,6 @@
|
||||||
"mode": "managed",
|
"mode": "managed",
|
||||||
"type": "test_instance",
|
"type": "test_instance",
|
||||||
"name": "test",
|
"name": "test",
|
||||||
"deposed": true,
|
|
||||||
"change": {
|
"change": {
|
||||||
"actions": [
|
"actions": [
|
||||||
"no-op"
|
"no-op"
|
||||||
|
|
Loading…
Reference in New Issue