From 97d799b9f0a6c5174aa1127e82b15bf2d45a3a83 Mon Sep 17 00:00:00 2001 From: Nitish Tiwari Date: Wed, 1 Jan 2020 21:55:09 +0530 Subject: [PATCH] doc: Update Kubernetes examples to use Readiness Checks (#8727) --- .../kubernetes/minio-distributed-headless-service.yaml | 1 + .../kubernetes/minio-distributed-statefulset.yaml | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/docs/orchestration/kubernetes/minio-distributed-headless-service.yaml b/docs/orchestration/kubernetes/minio-distributed-headless-service.yaml index a822d76eb..aaef50d43 100644 --- a/docs/orchestration/kubernetes/minio-distributed-headless-service.yaml +++ b/docs/orchestration/kubernetes/minio-distributed-headless-service.yaml @@ -5,6 +5,7 @@ metadata: labels: app: minio spec: + publishNotReadyAddresses: true clusterIP: None ports: - port: 9000 diff --git a/docs/orchestration/kubernetes/minio-distributed-statefulset.yaml b/docs/orchestration/kubernetes/minio-distributed-statefulset.yaml index 8a4fc35d2..79b1971ec 100644 --- a/docs/orchestration/kubernetes/minio-distributed-statefulset.yaml +++ b/docs/orchestration/kubernetes/minio-distributed-statefulset.yaml @@ -5,6 +5,7 @@ metadata: name: minio spec: serviceName: minio + podManagementPolicy: Parallel replicas: 4 selector: matchLabels: @@ -41,6 +42,15 @@ spec: port: 9000 initialDelaySeconds: 120 periodSeconds: 20 + # Readiness probe detects situations where MinIO server instance + # is not ready to accept connections. Kubernetes automatically + # stops all the traffic to the pods if readiness checks fail. + readinessProbe: + httpGet: + path: /minio/health/ready + port: 9000 + initialDelaySeconds: 120 + periodSeconds: 20 # These are converted to volume claims by the controller # and mounted at the paths mentioned above. volumeClaimTemplates: