Use tsp instad of podaffinity + version optional quotas
This commit is contained in:
@@ -7,22 +7,27 @@ spec:
|
|||||||
replicas: 1
|
replicas: 1
|
||||||
template:
|
template:
|
||||||
spec:
|
spec:
|
||||||
affinity:
|
|
||||||
podAntiAffinity:
|
|
||||||
preferredDuringSchedulingIgnoredDuringExecution:
|
|
||||||
- weight: 100
|
|
||||||
podAffinityTerm:
|
|
||||||
labelSelector:
|
|
||||||
matchExpressions:
|
|
||||||
- key: app.kubernetes.io/instance
|
|
||||||
operator: In
|
|
||||||
values:
|
|
||||||
- html-kube-tester
|
|
||||||
topologyKey: kubernetes.io/hostname
|
|
||||||
securityContext:
|
securityContext:
|
||||||
runAsNonRoot: true
|
runAsNonRoot: true
|
||||||
seccompProfile:
|
seccompProfile:
|
||||||
type: RuntimeDefault
|
type: RuntimeDefault
|
||||||
|
topologySpreadConstraints:
|
||||||
|
- maxSkew: 1
|
||||||
|
topologyKey: topology.kubernetes.io/zone
|
||||||
|
whenUnsatisfiable: DoNotSchedule
|
||||||
|
labelSelector:
|
||||||
|
matchLabels:
|
||||||
|
app.kubernetes.io/instance: html-kube-tester
|
||||||
|
matchLabelKeys:
|
||||||
|
- pod-template-hash
|
||||||
|
- maxSkew: 1
|
||||||
|
topologyKey: kubernetes.io/hostname
|
||||||
|
whenUnsatisfiable: ScheduleAnyway
|
||||||
|
labelSelector:
|
||||||
|
matchLabels:
|
||||||
|
app.kubernetes.io/instance: html-kube-tester
|
||||||
|
matchLabelKeys:
|
||||||
|
- pod-template-hash
|
||||||
initContainers:
|
initContainers:
|
||||||
- name: content-generator
|
- name: content-generator
|
||||||
image: quay.io/simbelmas/alpine-tools:stable
|
image: quay.io/simbelmas/alpine-tools:stable
|
||||||
@@ -61,21 +66,9 @@ spec:
|
|||||||
protocol: TCP
|
protocol: TCP
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
cpu: 1m
|
cpu: 10m
|
||||||
memory: 10Mi
|
|
||||||
limits:
|
limits:
|
||||||
cpu: 100m
|
cpu: 40m
|
||||||
memory: 50Mi
|
|
||||||
livenessProbe: &html-kube-tester-probe
|
|
||||||
httpGet:
|
|
||||||
path: /
|
|
||||||
port: 8080
|
|
||||||
timeoutSeconds: 5
|
|
||||||
periodSeconds: 15
|
|
||||||
failureThreshold: 10
|
|
||||||
readinessProbe:
|
|
||||||
<<: *html-kube-tester-probe
|
|
||||||
periodSeconds: 2
|
|
||||||
volumes:
|
volumes:
|
||||||
- name: init
|
- name: init
|
||||||
configMap:
|
configMap:
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ resources:
|
|||||||
- deployment.yaml
|
- deployment.yaml
|
||||||
- service.yaml
|
- service.yaml
|
||||||
- ingress.yaml
|
- ingress.yaml
|
||||||
|
#- resourceQuotas.yaml
|
||||||
|
|
||||||
replacements:
|
replacements:
|
||||||
- source:
|
- source:
|
||||||
|
|||||||
8
resourceQuotas.yaml
Normal file
8
resourceQuotas.yaml
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ResourceQuota
|
||||||
|
metadata:
|
||||||
|
name: compute-resources
|
||||||
|
spec:
|
||||||
|
hard:
|
||||||
|
requests.cpu: "100m"
|
||||||
|
limits.cpu: "50m"
|
||||||
Reference in New Issue
Block a user