cue-lang / cue

The home of the CUE language! Validate and define text-based and dynamic configuration
https://cuelang.org
Apache License 2.0
5.16k stars 297 forks source link

cuelang.org: multistep script PATH needs to be set in both Dockerfile and generated bash script #2629

Open myitcv opened 1 year ago

myitcv commented 1 year ago

What page were you looking at?

https://alpha.cuelang.org/

What version of the site were you looking at?

https://github.com/cue-lang/cuelang.org/commit/15f284192b61eea3f9bcd2ccd25ca39fa4efa99e

What did you do?

Worked on the preprocessor.

What did you expect?

To only have to set PATH in the Dockerfile behind the default image.

What did you see instead?

Had to set PATH in the Dockerfile and the bash script used as part of a multi-step script:

myitcv commented 7 months ago

We solved this rather more elegantly by introducing the concept of named versions the site configuration, such that the Dockerfile and runner now use:

https://github.com/cue-lang/cuelang.org/blob/bcf703c3b2d4cfbbab3d0b5cb779534793d4c223/internal/cmd/preprocessor/cmd/rootfile.go#L389

Quite why the default path in the Dockerfile doesn't work is still not clear, but this is less of an issue now.

jpluscplusm commented 4 months ago

Reopening, as this issue has affected the installation of Java and Maven in the runner's container image, requiring code changes to support what should be a simple envvar update: https://review.gerrithub.io/c/cue-lang/cuelang.org/+/1198698/7/internal/cmd/preprocessor/cmd/rootfile.go