add readeness/liveness routes

This commit is contained in:
Vbarinov
2023-03-20 14:40:18 +05:30
parent ac880ad719
commit 0088a0ee52
2 changed files with 9 additions and 2 deletions
+7
View File
@@ -31,6 +31,13 @@ class Clients(db.Model):
_tablename__ = 'clients'
id = db.Column(db.Integer, primary_key=True)
userip = db.Column(db.String(12))
@app.route("/alive")
def alive():
return "alive"
@app.route("/ready")
def ready():
return "ready"
@app.route("/")
def hello():
+2 -2
View File
@@ -51,11 +51,11 @@ spec:
protocol: TCP
livenessProbe:
httpGet:
path: /
path: /alive
port: http
readinessProbe:
httpGet:
path: /
path: /ready
port: http
resources:
{{- toYaml .Values.resources | nindent 12 }}