File tree Expand file tree Collapse file tree 4 files changed +9
-32
lines changed Expand file tree Collapse file tree 4 files changed +9
-32
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ var k0sImageComponents = map[string]string{
21
21
"registry.k8s.io/metrics-server/metrics-server" : "metrics-server" ,
22
22
"quay.io/k0sproject/kube-proxy" : "kube-proxy" ,
23
23
"quay.io/k0sproject/envoy-distroless" : "envoy-distroless" ,
24
- "registry.k8s.io/pause" : "pause" ,
25
24
}
26
25
27
26
var k0sComponents = map [string ]addonComponent {
@@ -60,14 +59,6 @@ var k0sComponents = map[string]addonComponent{
60
59
return fmt .Sprintf ("envoy-%d.%d" , opts .upstreamVersion .Major (), opts .upstreamVersion .Minor ())
61
60
},
62
61
},
63
- "pause" : {
64
- getWolfiPackageName : func (opts addonComponentOptions ) string {
65
- return fmt .Sprintf ("kubernetes-pause-%d.%d" , opts .upstreamVersion .Major (), opts .upstreamVersion .Minor ())
66
- },
67
- getWolfiPackageVersionComparison : func (opts addonComponentOptions ) string {
68
- return latestPatchComparison (opts .k0sVersion ) // pause package version follows the k8s version
69
- },
70
- },
71
62
}
72
63
73
64
var updateK0sImagesCommand = & cli.Command {
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -71,8 +71,7 @@ func overrideK0sImages(cfg *k0sv1beta1.ClusterConfig) {
71
71
cfg .Spec .Images .KubeProxy .Image = helpers .AddonImageFromComponentName ("kube-proxy" )
72
72
cfg .Spec .Images .KubeProxy .Version = Metadata .Images ["kube-proxy" ]
73
73
74
- cfg .Spec .Images .Pause .Image = helpers .AddonImageFromComponentName ("pause" )
75
- cfg .Spec .Images .Pause .Version = Metadata .Images ["pause" ]
74
+ cfg .Spec .Images .Pause .Image = fmt .Sprintf ("proxy.replicated.com/anonymous/%s" , cfg .Spec .Images .Pause .Image )
76
75
77
76
// TODO (salah): remove the following and uncomment when upstream PR for digest support is released: https://github.com/k0sproject/k0s/pull/4792
78
77
if cfg .Spec .Network != nil &&
Original file line number Diff line number Diff line change @@ -39,6 +39,7 @@ func TestListK0sImages(t *testing.T) {
39
39
if len (filtered ) == 0 {
40
40
t .Errorf ("ListK0sImages() = %v, want not empty" , filtered )
41
41
}
42
+ var foundPause bool
42
43
var foundEnvoyProxy bool
43
44
for _ , image := range filtered {
44
45
if strings .Contains (image , "kube-router" ) {
@@ -51,7 +52,10 @@ func TestListK0sImages(t *testing.T) {
51
52
t .Errorf ("ListK0sImages() = %v, want not to contain apiserver-network-proxy-agent" , filtered )
52
53
}
53
54
if strings .Contains (image , constant .KubePauseContainerImage ) {
54
- t .Errorf ("ListK0sImages() = %v, want the ec pause image" , filtered )
55
+ foundPause = true
56
+ if ! strings .HasPrefix (image , "proxy.replicated.com/anonymous/" ) {
57
+ t .Errorf ("ListK0sImages() = %v, want pause to be proxied" , filtered )
58
+ }
55
59
}
56
60
if strings .Contains (image , "envoy-distroless" ) {
57
61
foundEnvoyProxy = true
@@ -60,6 +64,9 @@ func TestListK0sImages(t *testing.T) {
60
64
}
61
65
}
62
66
}
67
+ if ! foundPause {
68
+ t .Errorf ("ListK0sImages() = %v, want to contain pause" , filtered )
69
+ }
63
70
if ! foundEnvoyProxy {
64
71
t .Errorf ("ListK0sImages() = %v, want to contain envoy-distroless" , filtered )
65
72
}
You can’t perform that action at this time.
0 commit comments