openshift-4.8: Update Dockerfile for pod yaml#873
openshift-4.8: Update Dockerfile for pod yaml#873sosiouxme merged 1 commit intoopenshift-eng:openshift-4.8from
Conversation
|
@umohnani8: No Bugzilla bug is referenced in the title of this pull request. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
Wait for openshift/kubernetes#633 to get in first. |
Build #1 |
|
@umohnani8: No Bugzilla bug is referenced in the title of this pull request. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
Now that ubi8/pause exists, maybe we could just migrate openshift to use that instead? |
|
@yselkowitz the ubi8/pause image is around 250MB as well, our goal here is to bring the size of the pause image down as much as possible. And doing a build from scratch creates a pod image that is about 1MB in size. |
|
standalone image size is not a factor because images work in layers. all of ocp is already based on ubi8, so using ubi8/pause comes with almost zero additional cost. in fact, this patch doesn't change the base of pod either. |
|
How is the base of the pod image staying the same with this patch? From what I understand, you point to the Dockerfile you want built in the yaml and it builds that to create the image. The new Dockerfile is https://github.com/openshift/kubernetes/pull/633/files, which uses scratch as the base. |
|
The image yamls specify images or streams which are to be the downstream base(s) of the image, which are then substituted in the |
|
Yeah, agree that having a base layer doesn't matter. We are more looking at per instance memory overhead at runtime vs go. If possible, we could make this dynamically linked instead. |
|
@yselkowitz got it, thanks for the info! How would we go about using the ubi8/pause image here instead? |
|
Actually, looking at the how the ubi8/pause image is built, https://catalog.redhat.com/software/containers/rhel8/pause/5f7812eb0eae6156657d4607?tag=8.3-11&container-tabs=dockerfile, it is just an infinite sleep which does not work for Openshift. We need pid reaping, which is provided by the pause.c binary from https://github.com/openshift/kubernetes/blob/master/build/pause/linux/pause.c. And we want to move to use pause.c instead of the Go binary we are currently using to help improve memory overhead at runtime. |
|
LGTM but sounds like we are waiting on openshift/kubernetes#633 |
|
@sosiouxme openshift/kubernetes#633 got merged, this is ready now. |
Build #2 |
Build #3 |
Build #4 |
Update the openshift-enterprise-pod.yaml to point to the Dockerfile under openshift/k8s/build/pause so we build a pod image containing the pause.c binary bringing down the pod image size from ~250MB to ~1MB. Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
|
This should be ready for ART review now. |
Build #5 |
|
@sosiouxme PTAL, this is ready :) |
Since openshift/kubernetes#633 and openshift-eng#873, builds for `openshift-enterprise-pod` started to fail because `glibc-static` could not get installed. This commit adds the rhel-8 repository for the glibc-static rpm.
Since openshift/kubernetes#633 and openshift-eng#873, builds for `openshift-enterprise-pod` started to fail because `glibc-static` could not get installed. This commit adds the rhel-8 repository for the glibc-static rpm.
Since openshift-eng/ocp-build-data#873, the pause image is built from openshift/kubernetes instead of openshift/images.
Since openshift-eng/ocp-build-data#873, the pause image is built from openshift/kubernetes instead of openshift/images. Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
Update the openshift-enterprise-pod.yaml to
point to the Dockerfile under openshift/k8s/build/pause
so we build a pod image containing the pause.c binary
bringing down the pod image size from ~250MB to ~1MB.
Signed-off-by: Urvashi Mohnani umohnani@redhat.com