jmccann / drone-terraform

Drone plugin for triggering Terraform deployments
http://plugins.drone.io/jmccann/terraform/
Apache License 2.0
86 stars 93 forks source link

Passing vars result in panic: json: cannot unmarshal #113

Closed jkritzen closed 1 year ago

jkritzen commented 4 years ago

When i try to pass Variables for Terraform i get a crude error:

1 time="2020-05-29T11:48:46Z" level=info msg="Drone Terraform Plugin Version" Revision=
2 panic: json: cannot unmarshal array into Go value of type map[string]string [recovered]
3 panic: json: cannot unmarshal array into Go value of type map[string]string
4  
5 goroutine 1 [running]:
6 github.com/urfave/cli.HandleAction.func1(0xc00019f710)
7 /go/pkg/mod/github.com/urfave/cli@v0.0.0-20161006035353-55f715e28c46/app.go:478 +0x22d
8 panic(0x82c820, 0xc000140780)
9 /usr/local/go/src/runtime/panic.go:969 +0x166
10 main.run(0xc000164780, 0x0, 0x0)
11 /drone/src/main.go:136 +0xd27
12 reflect.Value.call(0x81dae0, 0x8c4ed0, 0x13, 0x8a5bf5, 0x4, 0xc0001136c0, 0x1, 0x1, 0x58de1b, 0x8a7f1b, ...)
13 /usr/local/go/src/reflect/value.go:460 +0x8ab
14 reflect.Value.Call(0x81dae0, 0x8c4ed0, 0x13, 0xc0001136c0, 0x1, 0x1, 0x1, 0xc00012c9c0, 0x2)
15 /usr/local/go/src/reflect/value.go:321 +0xb4
16 github.com/urfave/cli.HandleAction(0x81dae0, 0x8c4ed0, 0xc000164780, 0x0, 0x0)
17 /go/pkg/mod/github.com/urfave/cli@v0.0.0-20161006035353-55f715e28c46/app.go:487 +0x1fa
18 github.com/urfave/cli.(*App).Run(0xc000102480, 0xc0001161c0, 0x1, 0x1, 0x0, 0x0)
19 /go/pkg/mod/github.com/urfave/cli@v0.0.0-20161006035353-55f715e28c46/app.go:245 +0x568
20 main.main()
21 /drone/src/main.go:119 +0xe74

The Pipeline: