-
Notifications
You must be signed in to change notification settings - Fork 994
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
Use Job instead of helm plugin to generate admission secret #191
Use Job instead of helm plugin to generate admission secret #191
Conversation
e297fc6
to
3ae3a29
Compare
@@ -98,3 +108,24 @@ spec: | |||
selector: | |||
app: volcano-admission | |||
sessionAffinity: None | |||
|
|||
--- | |||
apiVersion: batch/v1 |
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.
how about init container for admission controller?
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.
The difference is we need to run the init-container every time when new admission pod is created, but job would only execute once.
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.
That should be ok, as the script will remote the old one. If using job, how to make sure secret is generated before admission pod running?
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.
Pod will wait until the secret is ready because it will mount the secret. when used in init-container it will delete&recreate the secret every time when pod recreated.
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.
that's ok to me. BTW, Do we delete secret when uninstall volcano?
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.
yeah, we need investigate all of the uncleaned resource and remove them when uninstalling.
@@ -15,5 +15,16 @@ | |||
|
|||
FROM alpine:latest | |||
|
|||
# Install requirements |
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.
the file name should be Dockerfil.secret
, and only include gen-admission-secret.sh
.
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.
The sh file and binary are kept in one container in default since they are both simple logic and work for admission service, adding one more image can be complicated for maintain and the usage of end user.
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.
adding one more image can be complicated for maintain and the usage of end user
If so, why Dockerfile.only_binay
?
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.
ok, will remove this.
@@ -0,0 +1,19 @@ | |||
# Copyright 2019 The Volcano Authors. |
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.
The file name should be Dockerfile
.
ac82e79
to
e2865c9
Compare
e2865c9
to
77c296f
Compare
/lgtm |
Use Job instead of helm plugin to generate admission secret
See above
For #184