Switch secrets management to cryptic. #25
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
With the help of @staticfloat I tried switching the JuliaGPU secrets management solution to cryptic-buildkite-plugin. Example use case can be found in JuliaGPU/CUDA.jl#1687.
Although I got it mostly to work, there's a couple of issues that prevent me from using it. The biggest problem is that cryptic is designed to deal with much more complex scenarios, where there needs to be a chain of trust enforced by cryptography, and where secrets need to be (partially) available in as many cases as possible. For this purpose, pipelines can be partially trusted, need to be signed when changed, can (and should) include code that uses secrets in the hashing.
Meanwhile, most JuliaGPU CI users have a much simpler problem to solve: make sure CODECOV_TOKEN/DOCUMENTER_KEY is available for builds on
master
, and don't have them leak on PRs. With cryptic, that involves provisioning every repository with a repo key, putting almost every job in a secure pipeline (since most jobs submit coverage and thus use CODECOV_TOKEN), and including all ofdoc/
in the tree hashing (since you could otherwise leak the documenter key from a doctest). That doesn't scale.Meanwhile, our current system is much simpler: using a single keypair, and only decrypting secrets on the master branch. If we want to move forwards with using cryptic, it probably needs a mode where things are radically simplified.