From b7f16e83ba225bc5a57748f46c848d28afeb03ee Mon Sep 17 00:00:00 2001 From: Edward Viaene Date: Tue, 7 Aug 2018 09:59:30 +0000 Subject: [PATCH] liveness-readiness --- deployment/helloworld-liveness-readiness.yml | 29 ++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 deployment/helloworld-liveness-readiness.yml diff --git a/deployment/helloworld-liveness-readiness.yml b/deployment/helloworld-liveness-readiness.yml new file mode 100644 index 0000000..f2870ee --- /dev/null +++ b/deployment/helloworld-liveness-readiness.yml @@ -0,0 +1,29 @@ +apiVersion: extensions/v1beta1 +kind: Deployment +metadata: + name: helloworld-readiness +spec: + replicas: 3 + template: + metadata: + labels: + app: helloworld + spec: + containers: + - name: k8s-demo + image: wardviaene/k8s-demo + ports: + - name: nodejs-port + containerPort: 3000 + livenessProbe: + httpGet: + path: / + port: nodejs-port + initialDelaySeconds: 15 + timeoutSeconds: 30 + readinessProbe: + httpGet: + path: / + port: nodejs-port + initialDelaySeconds: 15 + timeoutSeconds: 30