Switch core master base images from debian to distroless

Signed-off-by: Davanum Srinivas <davanum@gmail.com>
This commit is contained in:
Yuwen Ma
2019-05-02 10:12:38 -07:00
committed by Davanum Srinivas
parent ba3bf32300
commit 1aa67fc525
12 changed files with 90 additions and 31 deletions

View File

@@ -71,14 +71,14 @@ func TestServerOverride(t *testing.T) {
c.mustInvokeFunc(
tc.env,
kubeAPIServerConfigScriptName,
[]string{"configure-helper.sh", kubeAPIServerConfigScriptName},
"etcd.template",
"testdata/kube-apiserver/base.template",
"testdata/kube-apiserver/etcd.template",
)
c.mustLoadPodFromManifest()
execArgs := c.pod.Spec.Containers[0].Command[2]
execArgs := strings.Join(c.pod.Spec.Containers[0].Command, " ")
for _, f := range tc.want {
if !strings.Contains(execArgs, f) {
t.Fatalf("Got %q, want it to contain %q", execArgs, f)
@@ -127,14 +127,14 @@ func TestStorageOptions(t *testing.T) {
c.mustInvokeFunc(
tc.env,
kubeAPIServerConfigScriptName,
[]string{"configure-helper.sh", kubeAPIServerConfigScriptName},
"etcd.template",
"testdata/kube-apiserver/base.template",
"testdata/kube-apiserver/etcd.template",
)
c.mustLoadPodFromManifest()
execArgs := c.pod.Spec.Containers[0].Command[2]
execArgs := strings.Join(c.pod.Spec.Containers[0].Command, " ")
for _, f := range tc.want {
if !strings.Contains(execArgs, f) {
t.Fatalf("Got %q, want it to contain %q", execArgs, f)
@@ -191,14 +191,14 @@ func TestTLSFlags(t *testing.T) {
c.mustInvokeFunc(
tc.env,
kubeAPIServerConfigScriptName,
[]string{"configure-helper.sh", kubeAPIServerConfigScriptName},
"etcd.template",
"testdata/kube-apiserver/base.template",
"testdata/kube-apiserver/etcd.template",
)
c.mustLoadPodFromManifest()
execArgs := c.pod.Spec.Containers[0].Command[2]
execArgs := strings.Join(c.pod.Spec.Containers[0].Command, " ")
for _, f := range tc.want {
if !strings.Contains(execArgs, f) {
t.Fatalf("Got %q, want it to contain %q", execArgs, f)