esc icon indicating copy to clipboard operation
esc copied to clipboard

Cannot Set Numerical Only Secrets

Open devstein opened this issue 9 months ago • 2 comments

What happened?

I'm trying to save secrets that only have numerical values

Example

$ esc env set dosu/staging --secret pulumiConfig.app:GH_APP_ID '1234'
Error: updating environment definition: [0]
Diags: secret values must be string literals

Output of pulumi about

CLI Version 3.114.0 Go Version go1.22.2 Go Compiler gc

Plugins KIND NAME VERSION resource gcp 7.19.0 language go unknown

Host OS darwin Version 14.4.1 Arch arm64

This project is written in go: executable='/opt/homebrew/bin/go' version='go version go1.21.3 darwin/arm64'

Backend Name pulumi.com URL https://app.pulumi.com/devstein User devstein Organizations devstein, src, dosu Token type personal

Dependencies: NAME VERSION github.com/pulumi/pulumi-gcp/sdk/v7 v7.19.0 github.com/pulumi/pulumi/sdk/v3 v3.113.3

Pulumi locates its logs in /var/folders/wq/7c2lyfl92v92vy__dqyhbkbc0000gn/T/ by default

Additional context

I'm able to save numerical config values, but not secrets

If you'd like help triaging issues like these try out Dosu. I built it because I've spent too much time on GitHub issues 😁

Contributing

Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

devstein avatar May 01 '24 02:05 devstein

Hey @cleverguy25 @pgavlin is there are a workaround for this before the 0.105? Is there an way to set a secret via the UI instead? Appreciate the help!

devstein avatar May 14 '24 21:05 devstein

Hah, interesting. The following should work:

$ esc env set dosu/staging --secret pulumiConfig.app:GH_APP_ID '"1234"'

pgavlin avatar May 14 '24 22:05 pgavlin

Pat, can we add documentation in the command line help?

cleverguy25 avatar May 23 '24 16:05 cleverguy25