-
Notifications
You must be signed in to change notification settings - Fork 41.3k
Add docker images for kubelet and kubelet-checker. #19177
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
Conversation
GCE e2e test build/test passed for commit 6ed3ae574ba237ff186cd9e013c97ee83a4973c3. |
ifndef VERSION | ||
$(error VERSION is undefined) | ||
endif | ||
cp ../../../_output/dockerized/bin/linux/${ARCH}/kubelet . |
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 local builds? Could we figure out some way to use dockerized
output sometimes and curl
download for k8s users? Or is this image only going to be used for the release?
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.
Why would you build your own image using released kubelet binary?
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.
Never mind, I was just thinking of how it had been earlier, when the Makefile
curl
ed for hyperkube
. However this is the way to go
|
||
max_seconds=10 | ||
container_id="${1}" | ||
hostport="${2:-https://127.0.0.1:10250}" |
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.
This is the full URL, not just the host port.
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.
Done.
@dchen1107 Can you please take a look or reassign for someone else in node team? @kubernetes/goog-node |
GCE e2e test build/test passed for commit 5dc7cbc7ecb20bef7ddfb52c24017ea5ab29a028. |
|
||
if [ $# -lt 1 ] || [ $# -gt 2 ]; then | ||
echo "Usage:" | ||
echo " kubelet-checker.sh <kubelet_container_id> [<kubelet_host_port>]" |
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.
s/kubelet_host_port/kubelet_url/
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.
Done
GCE e2e test build/test passed for commit 5dc7cbc7ecb20bef7ddfb52c24017ea5ab29a028. |
|
||
COPY kubelet-runner.sh /kubelet-runner.sh | ||
RUN chmod a+rx /kubelet-runner.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.
I would say that it's best to install the same packages as hyperkube
has. https://github.com/kubernetes/kubernetes/blob/master/cluster/images/hyperkube/Dockerfile#L3
Otherwise, the risk is very high that some package (that we already solved in /hyperkube kubelet
) is required to have, and another PR must fix that.
We should include the packages in this PR
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.
There are other requirements for hyperkube, e.g. we generate certs there. I'll add those that I believe are really needed.
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.
Yes, I know about the certs. That looks good.
GCE e2e build/test failed for commit d002ec0dd01668ce510671341c4a9753b265806a. |
GCE e2e test build/test passed for commit 1987f51. |
@@ -0,0 +1,5 @@ | |||
FROM alpine |
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.
Should this reference a specific version? Otherwise it seems like it won't be possible to re-create an identical image (e.g. from a release tag).
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.
3.3 is latest, maybe use that one?
PR needs rebase |
Add two docker images:
kubelet
- run kubelet via nsenter to workaround problems with namespace propagation.kubelet-checker
- script to monitor kubelet running in docker image; similar to https://github.com/kubernetes/kubernetes/blob/master/cluster/saltbase/salt/supervisor/kubelet-checker.shI'll send a followup PR to build and release those images.
This has similar changes to #19069.
In the long term I'd like to use those images by default in most cluster deployments (ref #18287)
@dchen1107 @vishh @roberthbailey @mikedanese
Ref #4869