From f37ae8fc352e0274a1631115491edda2cceda846 Mon Sep 17 00:00:00 2001 From: Iceber Gu Date: Sat, 6 Feb 2021 17:56:14 +0800 Subject: [PATCH] move to v3.4.1 for the pause image Signed-off-by: Iceber Gu --- client_test.go | 2 +- contrib/ansible/cri-containerd.yaml | 4 ++-- docs/PLUGINS.md | 2 +- docs/cri/config.md | 2 +- docs/cri/crictl.md | 23 +++++++++++------------ integration/main_test.go | 2 +- pkg/cri/config/config_unix.go | 2 +- pkg/cri/config/config_windows.go | 2 +- 8 files changed, 19 insertions(+), 20 deletions(-) diff --git a/client_test.go b/client_test.go index f8ded57f4..0db2eca7d 100644 --- a/client_test.go +++ b/client_test.go @@ -357,7 +357,7 @@ func TestImagePullSomePlatforms(t *testing.T) { opts = append(opts, WithPlatform(platform)) } - img, err := client.Fetch(ctx, "k8s.gcr.io/pause:3.1", opts...) + img, err := client.Fetch(ctx, "k8s.gcr.io/pause:3.4.1", opts...) if err != nil { t.Fatal(err) } diff --git a/contrib/ansible/cri-containerd.yaml b/contrib/ansible/cri-containerd.yaml index f7949601b..203abf5b7 100644 --- a/contrib/ansible/cri-containerd.yaml +++ b/contrib/ansible/cri-containerd.yaml @@ -61,6 +61,6 @@ # TODO This needs to be removed once we have consistent concurrent pull results - name: "Pre-pull pause container image" shell: | - /usr/local/bin/ctr pull k8s.gcr.io/pause:3.2 + /usr/local/bin/ctr pull k8s.gcr.io/pause:3.4.1 /usr/local/bin/crictl --runtime-endpoint unix:///run/containerd/containerd.sock \ - pull k8s.gcr.io/pause:3.2 + pull k8s.gcr.io/pause:3.4.1 diff --git a/docs/PLUGINS.md b/docs/PLUGINS.md index f45297ce8..fe16a2f01 100644 --- a/docs/PLUGINS.md +++ b/docs/PLUGINS.md @@ -244,7 +244,7 @@ example configuration stream_server_address = "" stream_server_port = "10010" enable_selinux = false - sandbox_image = "k8s.gcr.io/pause:3.1" + sandbox_image = "k8s.gcr.io/pause:3.4.1" stats_collect_period = 10 systemd_cgroup = false [plugins.cri.containerd] diff --git a/docs/cri/config.md b/docs/cri/config.md index 83b183968..5451f0a4c 100644 --- a/docs/cri/config.md +++ b/docs/cri/config.md @@ -40,7 +40,7 @@ version = 2 selinux_category_range = 1024 # sandbox_image is the image used by sandbox container. - sandbox_image = "k8s.gcr.io/pause:3.2" + sandbox_image = "k8s.gcr.io/pause:3.4.1" # stats_collect_period is the period (in seconds) of snapshots stats collection. stats_collect_period = 10 diff --git a/docs/cri/crictl.md b/docs/cri/crictl.md index 3a71575b5..d61d4d7e3 100644 --- a/docs/cri/crictl.md +++ b/docs/cri/crictl.md @@ -59,29 +59,28 @@ command. With the load command you inject a container image into the container runtime from a file. First you need to create a container image tarball. For example to create an image tarball for a pause container using Docker: ```console -$ docker pull k8s.gcr.io/pause-amd64:3.2 - 3.2: Pulling from pause-amd64 +$ docker pull k8s.gcr.io/pause:3.4.1 + 3.4.1: Pulling from pause 67ddbfb20a22: Pull complete - Digest: sha256:59eec8837a4d942cc19a52b8c09ea75121acc38114a2c68b98983ce9356b8610 - Status: Downloaded newer image for k8s.gcr.io/pause-amd64:3.2 -$ docker save k8s.gcr.io/pause-amd64:3.2 -o pause.tar + Digest: sha256:6c3835cab3980f11b83277305d0d736051c32b17606f5ec59f1dda67c9ba3810 + Status: Downloaded newer image for k8s.gcr.io/pause:3.4.1 +$ docker save k8s.gcr.io/pause:3.4.1 -o pause.tar ``` -Then use [`ctr`](https://github.com/containerd/containerd/blob/master/docs/man/ctr.1.md) -to load the container image into the container runtime: +Then use `ctr` to load the container image into the container runtime: ```console # The cri plugin uses the "k8s.io" containerd namespace. $ sudo ctr -n=k8s.io images import pause.tar - Loaded image: k8s.gcr.io/pause-amd64:3.2 + Loaded image: k8s.gcr.io/pause:3.4.1 ``` List images and inspect the pause image: ```console $ sudo crictl images IMAGE TAG IMAGE ID SIZE docker.io/library/busybox latest f6e427c148a76 728kB -k8s.gcr.io/pause-amd64 3.2 da86e6ba6ca19 746kB -$ sudo crictl inspecti da86e6ba6ca19 +k8s.gcr.io/pause 3.4.1 0f8457a4c2eca 686kB +$ sudo crictl inspecti 0f8457a4c2eca ... displays information about the pause image. -$ sudo crictl inspecti k8s.gcr.io/pause-amd64:3.2 +$ sudo crictl inspecti k8s.gcr.io/pause:3.4.1 ... displays information about the pause image. ``` @@ -201,7 +200,7 @@ $ crictl info } }, "streamServerPort": "10010", - "sandboxImage": "k8s.gcr.io/pause:3.2", + "sandboxImage": "k8s.gcr.io/pause:3.4.1", "statsCollectPeriod": 10, "containerdRootDir": "/var/lib/containerd", "containerdEndpoint": "unix:///run/containerd/containerd.sock", diff --git a/integration/main_test.go b/integration/main_test.go index ac46449f8..b46871f80 100644 --- a/integration/main_test.go +++ b/integration/main_test.go @@ -49,7 +49,7 @@ import ( const ( timeout = 1 * time.Minute - pauseImage = "k8s.gcr.io/pause:3.2" // This is the same with default sandbox image. + pauseImage = "k8s.gcr.io/pause:3.4.1" // This is the same with default sandbox image. k8sNamespace = constants.K8sContainerdNamespace ) diff --git a/pkg/cri/config/config_unix.go b/pkg/cri/config/config_unix.go index f04eecfc7..f91208538 100644 --- a/pkg/cri/config/config_unix.go +++ b/pkg/cri/config/config_unix.go @@ -56,7 +56,7 @@ func DefaultConfig() PluginConfig { TLSKeyFile: "", TLSCertFile: "", }, - SandboxImage: "k8s.gcr.io/pause:3.2", + SandboxImage: "k8s.gcr.io/pause:3.4.1", StatsCollectPeriod: 10, SystemdCgroup: false, MaxContainerLogLineSize: 16 * 1024, diff --git a/pkg/cri/config/config_windows.go b/pkg/cri/config/config_windows.go index 40766bed3..2a1c45753 100644 --- a/pkg/cri/config/config_windows.go +++ b/pkg/cri/config/config_windows.go @@ -54,7 +54,7 @@ func DefaultConfig() PluginConfig { TLSKeyFile: "", TLSCertFile: "", }, - SandboxImage: "mcr.microsoft.com/oss/kubernetes/pause:1.4.1", + SandboxImage: "k8s.gcr.io/pause:3.4.1", StatsCollectPeriod: 10, MaxContainerLogLineSize: 16 * 1024, Registry: Registry{