提交 d1436b40 编写于 作者: Z Zoltán Reegn

Remove ingress-nginx default backend

It's not needed since nginx 0.20.0.

See the following pull-requests for context:
* https://github.com/kubernetes/ingress-nginx/pull/3126
* https://github.com/kubernetes/ingress-nginx/pull/3156
上级 e86969d4
......@@ -12,51 +12,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: default-http-backend
namespace: kube-system
labels:
app.kubernetes.io/name: default-http-backend
app.kubernetes.io/part-of: kube-system
addonmanager.kubernetes.io/mode: Reconcile
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: default-http-backend
addonmanager.kubernetes.io/mode: Reconcile
template:
metadata:
labels:
app.kubernetes.io/name: default-http-backend
addonmanager.kubernetes.io/mode: Reconcile
spec:
terminationGracePeriodSeconds: 60
containers:
- name: default-http-backend
# Any image is permissible as long as:
# 1. It serves a 404 page at /
# 2. It serves 200 on a /healthz endpoint
image: {{default "gcr.io/google_containers" .ImageRepository}}/defaultbackend{{.ExoticArch}}:1.4
imagePullPolicy: IfNotPresent
livenessProbe:
httpGet:
path: /healthz
port: 8080
scheme: HTTP
initialDelaySeconds: 30
timeoutSeconds: 5
ports:
- containerPort: 8080
resources:
limits:
cpu: 20m
memory: 30Mi
requests:
cpu: 20m
memory: 30Mi
---
apiVersion: extensions/v1beta1
kind: Deployment
......@@ -121,7 +76,6 @@ spec:
hostPort: 18080
args:
- /nginx-ingress-controller
- --default-backend-service=$(POD_NAMESPACE)/default-http-backend
- --configmap=$(POD_NAMESPACE)/nginx-load-balancer-conf
- --tcp-services-configmap=$(POD_NAMESPACE)/tcp-services
- --udp-services-configmap=$(POD_NAMESPACE)/udp-services
......
# Copyright 2016 The Kubernetes Authors All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
apiVersion: v1
kind: Service
metadata:
name: default-http-backend
namespace: kube-system
labels:
app.kubernetes.io/name: default-http-backend
app.kubernetes.io/part-of: kube-system
kubernetes.io/minikube-addons: ingress
kubernetes.io/minikube-addons-endpoint: ingress
addonmanager.kubernetes.io/mode: Reconcile
spec:
type: NodePort
ports:
- port: 80
targetPort: 8080
nodePort: 30001
selector:
app.kubernetes.io/name: default-http-backend
\ No newline at end of file
......@@ -220,12 +220,6 @@ var Addons = map[string]*Addon{
"ingress-dp.yaml",
"0640",
true),
MustBinAsset(
"deploy/addons/ingress/ingress-svc.yaml.tmpl",
constants.AddonsPath,
"ingress-svc.yaml",
"0640",
false),
}, false, "ingress"),
"metrics-server": NewAddon([]*BinAsset{
MustBinAsset(
......
......@@ -129,10 +129,6 @@ func testIngressController(t *testing.T) {
t.Fatalf("waiting for ingress-controller to be up: %v", err)
}
if err := util.WaitForIngressDefaultBackendRunning(t); err != nil {
t.Fatalf("waiting for default-http-backend to be up: %v", err)
}
curdir, err := filepath.Abs("")
if err != nil {
t.Errorf("Error getting the file path for current directory: %s", curdir)
......
......@@ -359,28 +359,6 @@ func WaitForIngressControllerRunning(t *testing.T) error {
return nil
}
// WaitForIngressDefaultBackendRunning waits until ingress default backend pod to be running
func WaitForIngressDefaultBackendRunning(t *testing.T) error {
client, err := commonutil.GetClient()
if err != nil {
return errors.Wrap(err, "getting kubernetes client")
}
if err := commonutil.WaitForDeploymentToStabilize(client, "kube-system", "default-http-backend", time.Minute*10); err != nil {
return errors.Wrap(err, "waiting for default-http-backend deployment to stabilize")
}
if err := commonutil.WaitForService(client, "kube-system", "default-http-backend", true, time.Millisecond*500, time.Minute*10); err != nil {
return errors.Wrap(err, "waiting for default-http-backend service to be up")
}
if err := commonutil.WaitForServiceEndpointsNum(client, "kube-system", "default-http-backend", 1, time.Second*3, time.Minute*10); err != nil {
return errors.Wrap(err, "waiting for one default-http-backend endpoint to be up")
}
return nil
}
// WaitForGvisorControllerRunning waits for the gvisor controller pod to be running
func WaitForGvisorControllerRunning(t *testing.T) error {
client, err := commonutil.GetClient()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册