chore: update health check
This commit is contained in:
@@ -143,7 +143,9 @@ docker run --rm --name goma-gateway \
|
||||
```
|
||||
### 4. Healthcheck
|
||||
|
||||
- Goma Gateway health check: `/health/live`
|
||||
- Goma Gateway health check:
|
||||
- `/readyz`
|
||||
- `/healthz`
|
||||
- Routes health check: `/health/routes`
|
||||
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@ spec:
|
||||
containers:
|
||||
- name: goma-gateway
|
||||
image: jkaninda/goma-gateway
|
||||
command: ["goma","server"]
|
||||
command: ["/usr/local/bin/goma","server"]
|
||||
resources:
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
@@ -65,18 +65,16 @@ spec:
|
||||
- containerPort: 8080
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /health/live
|
||||
path: /healthz
|
||||
port: 8080
|
||||
initialDelaySeconds: 15
|
||||
periodSeconds: 30
|
||||
timeoutSeconds: 10
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /health/live
|
||||
path: /readyz
|
||||
port: 8080
|
||||
initialDelaySeconds: 15
|
||||
periodSeconds: 30
|
||||
timeoutSeconds: 10
|
||||
initialDelaySeconds: 5
|
||||
periodSeconds: 10
|
||||
volumeMounts:
|
||||
- name: config
|
||||
mountPath: /etc/goma/
|
||||
@@ -85,3 +83,5 @@ spec:
|
||||
configMap:
|
||||
name: goma-config
|
||||
```
|
||||
|
||||
## 4. Kubernetes Advanced deployment using CRDs
|
||||
12
docs/install/kuberntes-operator.md
Normal file
12
docs/install/kuberntes-operator.md
Normal file
@@ -0,0 +1,12 @@
|
||||
---
|
||||
title: Kubernetes Operator
|
||||
layout: default
|
||||
parent: Installation
|
||||
nav_order: 5
|
||||
---
|
||||
|
||||
# Kubernetes Operator
|
||||
|
||||
**Install the CRDs into the cluster:**
|
||||
|
||||
|
||||
@@ -27,7 +27,9 @@ gateway:
|
||||
healthyStatuses: [200,404] # Healthy statuses
|
||||
```
|
||||
|
||||
- Goma Gateway healthcheck: `/health/live`
|
||||
- Goma Gateway health check:
|
||||
- `/readyz`
|
||||
- `/healthz`
|
||||
- Routes health check: `health/routes`
|
||||
|
||||
### Gateway healthcheck response:
|
||||
|
||||
@@ -14,7 +14,7 @@ spec:
|
||||
containers:
|
||||
- name: goma-gateway
|
||||
image: jkaninda/goma-gateway
|
||||
command: ["goma","server"]
|
||||
command: ["/usr/local/bin/goma","server"]
|
||||
resources:
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
@@ -23,18 +23,16 @@ spec:
|
||||
- containerPort: 8080
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /health/live
|
||||
path: /healthz
|
||||
port: 8080
|
||||
initialDelaySeconds: 15
|
||||
periodSeconds: 30
|
||||
timeoutSeconds: 10
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /health/live
|
||||
path: /readyz
|
||||
port: 8080
|
||||
initialDelaySeconds: 15
|
||||
periodSeconds: 30
|
||||
timeoutSeconds: 10
|
||||
initialDelaySeconds: 5
|
||||
periodSeconds: 10
|
||||
volumeMounts:
|
||||
- name: config
|
||||
mountPath: /etc/goma/
|
||||
|
||||
@@ -78,13 +78,13 @@ func (gatewayServer GatewayServer) Initialize() *mux.Router {
|
||||
}
|
||||
// Routes health check
|
||||
if !gateway.DisableHealthCheckStatus {
|
||||
r.HandleFunc("/healthz", heath.HealthCheckHandler).Methods("GET")
|
||||
r.HandleFunc("/health/routes", heath.HealthCheckHandler).Methods("GET")
|
||||
}
|
||||
|
||||
// Health check
|
||||
r.HandleFunc("/health/live", heath.HealthReadyHandler).Methods("GET")
|
||||
r.HandleFunc("/readyz", heath.HealthReadyHandler).Methods("GET")
|
||||
r.HandleFunc("/healthz", heath.HealthReadyHandler).Methods("GET")
|
||||
// Enable common exploits
|
||||
if gateway.BlockCommonExploits {
|
||||
logger.Info("Block common exploits enabled")
|
||||
|
||||
Reference in New Issue
Block a user