-
Notifications
You must be signed in to change notification settings - Fork 37
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
Clean up helm/config.go #9
Comments
Currently, there's some code that tries to guess which config fields might show up in the It probably makes more sense to allow all fields to come from a non-prefixed env var. It should be a small change to Make sure to confirm that
|
I'm leaving the no-op test file in place because my next step is to add new behavior that will require testing.
Trying to guess in advance which part of the config a user will put in the `settings` section and which they'll put in `environment` is a fool's errand. Just let everything go in either place. The ServiceAccount field only had an `envconfig` tag (as opposed to `split_words`) because that triggered envconfig to look for the non- prefixed form. Now that we're finding non-prefixed forms of everything, we can use the clearer/more concise tag. Note that TestPopulateWithConflictingVariables isn't meant to say "here's what behavior we *want*" so much as "here's what the behavior *is*." I don't think one thing is any better than the other, but we should know which one we're getting.
Redacting KubeToken may not be sufficient, since it's possible that someone would put secrets in Values or StringValues. Unilaterally redacting those seems unhelpful, though, since they may be the very thing the user is trying to debug. I've settled on redacting the obvious field without trying to promise that all sensitive data will be hidden.
The
Config
struct in internal/helm/config.go defines the interface betweendrone-helm3
and a project's Drone settings. As such, it should be clear and well-documented:Config
struct makes sense to you—it makes sense to me, but I'm a poor judge since I already know all the things it's telling me.helm upgrade
" comments; they aren't particularly accuratehelmCommand
; that responsibility lies with thedetermineSteps
function ininternal/helm/plan.go
.inthe
typo on line 8 🙃The text was updated successfully, but these errors were encountered: