-
Notifications
You must be signed in to change notification settings - Fork 231
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
make wrapper server work with distroless-based images #3070
Conversation
Thanks! The code for those functions is pretty small (50-100 lines each). We could take one and add it to the demo functions as an example of a distroless function, or we could convert an existing function to distroless. Example Dockerfile:
|
kpt fn eval "${DESTINATION}" --image set-image:v0.1.0 --fn-config set-image-config.yaml | ||
rm set-image-config.yaml |
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.
can kpt accept function config on stdin?
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.
No. it doesn't. kpt fn eval
does accept stdin but for entire resourcelist.
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.
Most customization in create-deployment-blueprint.sh can be converted to a kpt pipeline.
kpt fn eval "${DESTINATION}" --image set-image:v0.1.0 --fn-config set-image-config.yaml | ||
rm set-image-config.yaml |
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.
No. it doesn't. kpt fn eval
does accept stdin but for entire resourcelist.
I'm going to merge this PR and will add an e2e test in a follow-up PR. |
Creating this PR sooner to unblock other folks.
I will add an distroless-base KRM function in
gcr.io/kpt-fn-demo
and then add an e2e test for it.Alternatively, we can use something like
gcr.io/cad-demo-sdk/set-namespace:latest
, but I'm not sure ifgcr.io/cad-demo-sdk
will be deleted later.We can also consider mirroring an image from
gcr.io/cad-demo-sdk
togcr.io/kpt-fn-demo
for testing purpose only.