Skip to content

Commit b8596a5

Browse files
committed
Add startup probes so that the demo apps are faster recognised as ready by kubernetes
1 parent 25ef528 commit b8596a5

10 files changed

Lines changed: 69 additions & 0 deletions

File tree

demo-targets/bodgeit/templates/deployment.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,14 @@ spec:
3838
- name: http
3939
containerPort: 8080
4040
protocol: TCP
41+
startupProbe:
42+
httpGet:
43+
path: /
44+
port: http
45+
periodSeconds: 3
46+
failureThreshold: 30
47+
successThreshold: 1
48+
timeoutSeconds: 5
4149
livenessProbe:
4250
httpGet:
4351
path: /

demo-targets/dummy-ssh/templates/deployment.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ spec:
3838
- name: ssh
3939
containerPort: 22
4040
protocol: TCP
41+
startupProbe:
42+
tcpSocket:
43+
port: 22
44+
periodSeconds: 3
45+
failureThreshold: 30
46+
successThreshold: 1
4147
livenessProbe:
4248
tcpSocket:
4349
port: 22

demo-targets/http-webhook/templates/deployment.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,13 @@ spec:
4949
- name: http
5050
containerPort: 8080
5151
protocol: TCP
52+
startupProbe:
53+
httpGet:
54+
path: /
55+
port: http
56+
periodSeconds: 3
57+
failureThreshold: 30
58+
successThreshold: 1
5259
resources:
5360
{{- toYaml .Values.resources | nindent 12 }}
5461
{{- with .Values.nodeSelector }}

demo-targets/juice-shop/templates/deployment.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,13 @@ spec:
5151
- name: http
5252
containerPort: 3000
5353
protocol: TCP
54+
startupProbe:
55+
httpGet:
56+
path: /
57+
port: http
58+
periodSeconds: 3
59+
failureThreshold: 30
60+
successThreshold: 1
5461
livenessProbe:
5562
httpGet:
5663
path: /

demo-targets/old-joomla/templates/deployment.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,13 @@ spec:
3838
- name: http
3939
containerPort: 80
4040
protocol: TCP
41+
startupProbe:
42+
httpGet:
43+
path: /
44+
port: http
45+
periodSeconds: 3
46+
failureThreshold: 30
47+
successThreshold: 1
4148
livenessProbe:
4249
httpGet:
4350
path: /

demo-targets/old-typo3/templates/deployment.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,13 @@ spec:
3838
- name: http
3939
containerPort: 80
4040
protocol: TCP
41+
startupProbe:
42+
httpGet:
43+
path: /
44+
port: http
45+
periodSeconds: 3
46+
failureThreshold: 30
47+
successThreshold: 1
4148
livenessProbe:
4249
httpGet:
4350
path: /

demo-targets/old-wordpress/templates/deployment.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,13 @@ spec:
3838
- name: http
3939
containerPort: 80
4040
protocol: TCP
41+
startupProbe:
42+
httpGet:
43+
path: /
44+
port: http
45+
periodSeconds: 3
46+
failureThreshold: 30
47+
successThreshold: 1
4148
livenessProbe:
4249
httpGet:
4350
path: /

demo-targets/swagger-petstore/templates/deployment.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,13 @@ spec:
5252
- name: http
5353
containerPort: 8080
5454
protocol: TCP
55+
startupProbe:
56+
httpGet:
57+
path: /
58+
port: http
59+
periodSeconds: 3
60+
failureThreshold: 30
61+
successThreshold: 1
5562
livenessProbe:
5663
httpGet:
5764
path: /

demo-targets/unsafe-https/templates/deployment.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ spec:
3838
- name: https
3939
containerPort: 443
4040
protocol: TCP
41+
startupProbe:
42+
tcpSocket:
43+
port: 443
44+
periodSeconds: 3
45+
failureThreshold: 30
46+
successThreshold: 1
4147
livenessProbe:
4248
tcpSocket:
4349
port: 443

demo-targets/vulnerable-log4j/templates/deployment.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,13 @@ spec:
3838
- name: http
3939
containerPort: 8080
4040
protocol: TCP
41+
startupProbe:
42+
httpGet:
43+
path: /
44+
port: http
45+
periodSeconds: 3
46+
failureThreshold: 30
47+
successThreshold: 1
4148
resources:
4249
{{- toYaml .Values.resources | nindent 12 }}
4350
{{- with .Values.nodeSelector }}

0 commit comments

Comments
 (0)