Migration e2e installation to helm (#5086)
This commit is contained in:
parent
4b5c39e97b
commit
37c24b0df5
46 changed files with 321 additions and 725 deletions
|
|
@ -10,15 +10,16 @@ RUN apk add -U --no-cache \
|
|||
libc6-compat \
|
||||
openssl
|
||||
|
||||
RUN curl -sSL https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash \
|
||||
&& helm repo add stable https://kubernetes-charts.storage.googleapis.com \
|
||||
&& helm repo update
|
||||
|
||||
COPY --from=BASE /go/bin/ginkgo /usr/local/bin/
|
||||
COPY --from=BASE /usr/local/bin/kubectl /usr/local/bin/
|
||||
|
||||
COPY e2e.sh /e2e.sh
|
||||
COPY cloud-generic /cloud-generic
|
||||
COPY cluster-wide /cluster-wide
|
||||
COPY overlay /overlay
|
||||
COPY namespace-overlays /namespace-overlays
|
||||
RUN sed -E -i 's|^- .*deploy/cloud-generic$|- ../cloud-generic|' /overlay/kustomization.yaml
|
||||
|
||||
COPY wait-for-nginx.sh /
|
||||
COPY e2e.test /
|
||||
|
||||
|
|
|
|||
|
|
@ -22,8 +22,6 @@ endif
|
|||
|
||||
cp ../e2e/e2e.test .
|
||||
cp ../e2e/wait-for-nginx.sh .
|
||||
cp -r ../../deploy/cloud-generic .
|
||||
cp -r ../../deploy/cluster-wide .
|
||||
|
||||
docker buildx build \
|
||||
--load \
|
||||
|
|
|
|||
|
|
@ -1,18 +0,0 @@
|
|||
- op: replace
|
||||
path: /spec/template/spec/containers/0/livenessProbe/httpGet/path
|
||||
value: /not-healthz
|
||||
- op: replace
|
||||
path: /spec/template/spec/containers/0/livenessProbe/httpGet/port
|
||||
value: 9090
|
||||
- op: replace
|
||||
path: /spec/template/spec/containers/0/readinessProbe/httpGet/path
|
||||
value: /not-healthz
|
||||
- op: replace
|
||||
path: /spec/template/spec/containers/0/readinessProbe/httpGet/port
|
||||
value: 9090
|
||||
- op: add
|
||||
path: /spec/template/spec/containers/0/args/-
|
||||
value: --health-check-path=/not-healthz
|
||||
- op: add
|
||||
path: /spec/template/spec/containers/0/args/-
|
||||
value: --healthz-port=9090
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
patchesJson6902:
|
||||
- target:
|
||||
group: apps
|
||||
version: v1
|
||||
kind: Deployment
|
||||
name: nginx-ingress-controller
|
||||
path: deployment-patch.yaml
|
||||
bases:
|
||||
- ../../overlay
|
||||
|
|
@ -0,0 +1,33 @@
|
|||
controller:
|
||||
image:
|
||||
repository: ingress-controller/nginx-ingress-controller
|
||||
tag: 1.0.0-dev
|
||||
extraArgs:
|
||||
healthz-port: "9090"
|
||||
# e2e tests do not require information about ingress status
|
||||
update-status: "false"
|
||||
|
||||
scope:
|
||||
enabled: true
|
||||
config:
|
||||
worker-processes: "1"
|
||||
readinessProbe:
|
||||
port: 9090
|
||||
initialDelaySeconds: 1
|
||||
livenessProbe:
|
||||
port: 9090
|
||||
initialDelaySeconds: 1
|
||||
podLabels:
|
||||
app.kubernetes.io/name: ingress-nginx
|
||||
app.kubernetes.io/part-of: ingress-nginx
|
||||
service:
|
||||
type: NodePort
|
||||
labels:
|
||||
app.kubernetes.io/name: ingress-nginx
|
||||
app.kubernetes.io/part-of: ingress-nginx
|
||||
|
||||
defaultBackend:
|
||||
enabled: false
|
||||
|
||||
rbac:
|
||||
create: false
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
- op: replace
|
||||
path: /spec/template/spec/containers/0/ports/0/containerPort
|
||||
value: 1080
|
||||
- op: replace
|
||||
path: /spec/template/spec/containers/0/ports/1/containerPort
|
||||
value: 1443
|
||||
- op: add
|
||||
path: /spec/template/spec/containers/0/args/-
|
||||
value: --http-port=1080
|
||||
- op: add
|
||||
path: /spec/template/spec/containers/0/args/-
|
||||
value: --https-port=1443
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
patchesJson6902:
|
||||
- target:
|
||||
group: apps
|
||||
version: v1
|
||||
kind: Deployment
|
||||
name: nginx-ingress-controller
|
||||
path: deployment-patch.yaml
|
||||
- target:
|
||||
version: v1
|
||||
kind: Service
|
||||
name: ingress-nginx
|
||||
path: service-patch.yaml
|
||||
bases:
|
||||
- ../../overlay
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
- op: replace
|
||||
path: /spec/ports/0/targetPort
|
||||
value: 1080
|
||||
- op: replace
|
||||
path: /spec/ports/1/targetPort
|
||||
value: 1443
|
||||
|
|
@ -0,0 +1,34 @@
|
|||
controller:
|
||||
image:
|
||||
repository: ingress-controller/nginx-ingress-controller
|
||||
tag: 1.0.0-dev
|
||||
containerPort:
|
||||
http: "1080"
|
||||
https: "1443"
|
||||
|
||||
extraArgs:
|
||||
http-port: "1080"
|
||||
https-port: "1443"
|
||||
# e2e tests do not require information about ingress status
|
||||
update-status: "false"
|
||||
|
||||
scope:
|
||||
enabled: true
|
||||
|
||||
config:
|
||||
worker-processes: "1"
|
||||
podLabels:
|
||||
app.kubernetes.io/name: ingress-nginx
|
||||
app.kubernetes.io/part-of: ingress-nginx
|
||||
service:
|
||||
name: ingress-nginx
|
||||
type: NodePort
|
||||
labels:
|
||||
app.kubernetes.io/name: ingress-nginx
|
||||
app.kubernetes.io/part-of: ingress-nginx
|
||||
|
||||
defaultBackend:
|
||||
enabled: false
|
||||
|
||||
rbac:
|
||||
create: false
|
||||
|
|
@ -1,35 +0,0 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: nginx-ingress-controller
|
||||
spec:
|
||||
template:
|
||||
spec:
|
||||
terminationGracePeriodSeconds: 0
|
||||
initContainers:
|
||||
- name: enable-coredump
|
||||
image: busybox
|
||||
command:
|
||||
- /bin/sh
|
||||
- -c
|
||||
- |
|
||||
ulimit -c unlimited
|
||||
echo "/tmp/core.%e.%p" > /proc/sys/kernel/core_pattern
|
||||
sysctl -w fs.suid_dumpable=2
|
||||
securityContext:
|
||||
privileged: true
|
||||
containers:
|
||||
- name: nginx-ingress-controller
|
||||
livenessProbe:
|
||||
timeoutSeconds: 1
|
||||
initialDelaySeconds: 1
|
||||
periodSeconds: 2
|
||||
readinessProbe:
|
||||
timeoutSeconds: 1
|
||||
initialDelaySeconds: 1
|
||||
periodSeconds: 2
|
||||
lifecycle:
|
||||
preStop:
|
||||
exec:
|
||||
command:
|
||||
- /wait-shutdown
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
- op: add
|
||||
path: /spec/template/spec/containers/0/args/-1
|
||||
value: "--watch-namespace=$(POD_NAMESPACE)"
|
||||
|
|
@ -1,34 +0,0 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
bases:
|
||||
- ../../../deploy/cloud-generic
|
||||
configMapGenerator:
|
||||
- name: nginx-configuration
|
||||
behavior: merge
|
||||
literals:
|
||||
- worker-processes=1
|
||||
patchesStrategicMerge:
|
||||
- deployment-e2e.yaml
|
||||
- service-protocol-tcp.yaml
|
||||
patchesJson6902:
|
||||
- path: deployment-namespace-patch.yaml
|
||||
target:
|
||||
group: apps
|
||||
kind: Deployment
|
||||
name: nginx-ingress-controller
|
||||
version: v1
|
||||
- path: service-cluster-patch.yaml
|
||||
target:
|
||||
kind: Service
|
||||
name: ingress-nginx
|
||||
version: v1
|
||||
- path: role.yaml
|
||||
target:
|
||||
group: rbac.authorization.k8s.io
|
||||
kind: Role
|
||||
name: nginx-ingress-role
|
||||
version: v1beta1
|
||||
images:
|
||||
- name: quay.io/kubernetes-ingress-controller/nginx-ingress-controller
|
||||
newName: ingress-controller/nginx-ingress-controller
|
||||
newTag: dev
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
- op: add
|
||||
path: /rules/1/resourceNames/-1
|
||||
value: "ingress-controller-leader-testclass"
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
- op: remove
|
||||
path: /spec/externalTrafficPolicy
|
||||
- op: remove
|
||||
path: /spec/type
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: ingress-nginx
|
||||
spec:
|
||||
ports:
|
||||
- name: http
|
||||
port: 80
|
||||
targetPort: 80
|
||||
protocol: TCP
|
||||
- name: https
|
||||
port: 443
|
||||
targetPort: 443
|
||||
protocol: TCP
|
||||
Loading…
Add table
Add a link
Reference in a new issue