sticky-bear-14421
04/12/2021, 7:33 AMpulumi config set adminRole "foobar"My code has a string variable defined I will load the value into ..
var adminRole string
conf := config.New(ctx, "")
conf.RequireObject("adminRole", &adminRole)But, running pulumi up fails with an error I fail to understand:
panic: fatal: A failure has occurred: unable to unmarshall required configuration variable 'my_project:adminRole'; invalid character 'o' in literal false (expecting 'a')
lemon-agent-27707
04/12/2021, 7:35 PMconfig.require
does return a string. requireObject
will read the string value and attempt to unmarshal it into the provided interface (a string in your case). I image that you probably want require
in this casesticky-bear-14421
04/13/2021, 7:16 AM