Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

apply with -e jsonnet fails #351

Closed
williamhbaker opened this issue Dec 29, 2021 · 1 comment · Fixed by #370
Closed

apply with -e jsonnet fails #351

williamhbaker opened this issue Dec 29, 2021 · 1 comment · Fixed by #370
Assignees

Comments

@williamhbaker
Copy link
Contributor

Applying a jsonnet template causes an error when using the CLI with a cloud host, and will soon cause an error with an OSS host: influxdata/influxdb#23030

To reproduce, the file at https://github.com/influxdata/influxdb/blob/master/pkger/testdata/bucket_associates_labels.jsonnet can be used with influx apply -e jsonnet -f bucket_associates_labels.jsonnet with the file saved locally, or even influx apply -e jsonnet -u https://github.com/influxdata/influxdb/blob/master/pkger/testdata/bucket_associates_labels.jsonnet for a hosted file.

Since server-side jsonnet parsing is now disabled, we will need to parse it in the client to be able to handle jsonnet templates.

@serenibyss
Copy link
Contributor

serenibyss commented Jan 11, 2022

The CLI does seem to be able to parse jsonnet templates, the error seems to be somewhere else. If you run the command listed above as:

cat ./bucket_associates_labels.jsonnet | influx apply -e jsonnet

it works as expected and causes no issues. So I think this issue is something else other than the server losing jsonnet parsing abilities, and is somewhere in its handling of the -f flag

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants