Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
93f8d41aac | ||
|
|
f5a786386f |
+42
-4
@@ -4,14 +4,15 @@ metadata:
|
||||
name: reverse-proxy
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
#kind: Deployment
|
||||
kind: DaemonSet
|
||||
metadata:
|
||||
name: reverse-proxy
|
||||
namespace: reverse-proxy
|
||||
annotations:
|
||||
reloader.stakater.com/search: "true"
|
||||
spec:
|
||||
replicas: 1
|
||||
#replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: reverse-proxy
|
||||
@@ -20,7 +21,9 @@ spec:
|
||||
labels:
|
||||
app: reverse-proxy
|
||||
spec:
|
||||
nodeName: kube-master
|
||||
hostNetwork: true
|
||||
dnsPolicy: ClusterFirstWithHostNet # required when hostNetwork: true
|
||||
#nodeName: kube-master
|
||||
# Allows the sidecar to see and signal the Nginx process
|
||||
shareProcessNamespace: true
|
||||
containers:
|
||||
@@ -63,6 +66,7 @@ spec:
|
||||
limits:
|
||||
cpu: 250m
|
||||
memory: 250Mi
|
||||
|
||||
- name: watcher
|
||||
image: alpine:latest
|
||||
command: ["/bin/sh", "-c"]
|
||||
@@ -88,7 +92,15 @@ spec:
|
||||
volumeMounts:
|
||||
- name: blacklisted-memory-volume
|
||||
mountPath: /etc/nginx/blacklisted.d/
|
||||
|
||||
tolerations:
|
||||
# these tolerations are to have the daemonset runnable on control plane nodes
|
||||
# remove them if your control plane nodes should not run pods
|
||||
- key: node-role.kubernetes.io/control-plane
|
||||
operator: Exists
|
||||
effect: NoSchedule
|
||||
- key: node-role.kubernetes.io/master
|
||||
operator: Exists
|
||||
effect: NoSchedule
|
||||
|
||||
volumes:
|
||||
- name: reverse-proxy-log
|
||||
@@ -158,3 +170,29 @@ spec:
|
||||
type: NodePort
|
||||
selector:
|
||||
app: reverse-proxy
|
||||
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: reverse-proxy-load
|
||||
namespace: reverse-proxy
|
||||
annotations:
|
||||
spec:
|
||||
ipFamilyPolicy: PreferDualStack
|
||||
ports:
|
||||
- name: http
|
||||
port: 80
|
||||
targetPort: rp-port-http
|
||||
protocol: TCP
|
||||
|
||||
- name: https
|
||||
port: 443
|
||||
targetPort: rp-port-https
|
||||
protocol: TCP
|
||||
|
||||
|
||||
type: LoadBalancer
|
||||
externalTrafficPolicy: Local
|
||||
selector:
|
||||
app: reverse-proxy
|
||||
|
||||
Reference in New Issue
Block a user