-
Notifications
You must be signed in to change notification settings - Fork 245
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
ref(worker): move env var processing to the top #358
ref(worker): move env var processing to the top #358
Conversation
I'm trying to figure out how to best bubble this env var reference up to the /cc @jchanam and @adamreese |
I think this is a much better approach. The only thing that I don't know is: Why to have the default value defined twice? This is what I tried to do on my first approach, but couldn't achieve it :( |
@technosophos Just trying to figure out your intension - from
to
on the other hand of your current change? |
Ugh... that was my mistake, @mumoshu. I need to fix that. |
392c7ef
to
0cc95f9
Compare
Okay, refactored this based on some OTS input from @adamreese . This new version should be a little bit more future-proof, and is based on an idea he found in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't forget to run make format
brigade-worker/src/k8s.ts
Outdated
@@ -142,18 +166,18 @@ export class JobRunner implements jobs.JobRunner { | |||
event: BrigadeEvent; | |||
job: jobs.Job; | |||
client: kubernetes.Core_v1Api; | |||
localOptions: KubernetesOptions; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i would just call this options
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
This is a minor refactor to move an env var reference to the top.
0cc95f9
to
b1bd071
Compare
This is a minor refactor to move an env var reference to the top.