From 512d43fee133bc9cd82acd6f0ca767e5d7e07aca Mon Sep 17 00:00:00 2001 From: Srishti Thakkar Date: Fri, 4 Sep 2020 16:45:27 +0530 Subject: [PATCH] Issue 107: Liveness Probes for schema registry deployment (#108) * Issue 107: Liveness Probes for schema registry deployment Signed-off-by: SrishT --- charts/schema-registry/README.md | 7 +++---- charts/schema-registry/templates/deployment.yaml | 8 +++++--- charts/schema-registry/values.yaml | 1 - 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/charts/schema-registry/README.md b/charts/schema-registry/README.md index eec0e66ba..939f98018 100644 --- a/charts/schema-registry/README.md +++ b/charts/schema-registry/README.md @@ -52,6 +52,9 @@ The following table lists the configurable parameters of the schema registry cha | `image.repository` | Repository for schema registry image | `pravega/schema-registry` | | `image.tag` | Tag for schema registry image | `0.0.1` | | `image.pullPolicy` | Pull policy for schema registry image | `IfNotPresent` | +| `serviceAccount.create` | Whether to create a service account | `true` | +| `serviceAccount.name` | Name of the service account | `schema-registry` | +| `serviceAccount.annotations` | Annotations to be added to the service account | | | `service.type` | Schema registry service type | `LoadBalancer` | | `service.port` | Schema registry service port | `9092` | | `ingress.enabled` | Whether to expose as an ingress resource | `false` | @@ -61,9 +64,6 @@ The following table lists the configurable parameters of the schema registry cha | `ingress.tls` | TLS configuration for the ingress | `[]` | | `controllerUri` | URL of the Pravega Controller service | `tcp://localhost:9090` | | `storeType` | Type of store to be used | `Pravega` | -| `serviceAccount.create` | Whether to create a service account | `true` | -| `serviceAccount.name` | Name of the service account | `schema-registry` | -| `serviceAccount.annotations` | Annotations to be added to the service account | | | `authentication.enabled` | Whether to enable authentication and authorization | `false` | | `authentication.passwordAuthSecret` | Name of the secret generated by the user from the userPasswordFile | | | `authentication.userPasswordFile` | Path of the file containing user credentials and ACLs, for the PasswordAuthHandler | | @@ -71,6 +71,5 @@ The following table lists the configurable parameters of the schema registry cha | `tls.enabled` | Whether to enable TLS | `false` | | `tls.secret` | Name of the secret generated by the user from the tls certFile, trustStore, keyFile and keyPasswordFile | | | `tls.certFile` | Path of the X.509 PEM-encoded server certificate file for the service | | -| `tls.trustStore` | Path of the PEM-encoded truststore file for TLS connections | | | `tls.keyFile` | Path of the PEM-encoded private key file for the service | | | `tls.keyPasswordFile` | Path of the PEM-encoded private key password file for the service | | diff --git a/charts/schema-registry/templates/deployment.yaml b/charts/schema-registry/templates/deployment.yaml index 5cb85ddcf..fdd5b4b56 100644 --- a/charts/schema-registry/templates/deployment.yaml +++ b/charts/schema-registry/templates/deployment.yaml @@ -41,9 +41,11 @@ spec: protocol: TCP livenessProbe: initialDelaySeconds: 2 - httpGet: - path: /ping - port: rest + exec: + command: + - sh + - -c + - netstat -ltn 2> /dev/null | grep {{ .Values.service.port }} || ss -ltn 2> /dev/null | grep {{ .Values.service.port }} {{- if or .Values.authentication.enabled .Values.tls.enabled }} volumeMounts: {{- if .Values.authentication.enabled }} diff --git a/charts/schema-registry/values.yaml b/charts/schema-registry/values.yaml index 23694a092..9cfbb4920 100644 --- a/charts/schema-registry/values.yaml +++ b/charts/schema-registry/values.yaml @@ -76,6 +76,5 @@ tls: ## tls is enabled secret: certFile: - trustStore: keyFile: keyPasswordFile: