Skip to content

Commit

Permalink
feat: added health endpoint for the deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
whykay-01 committed Apr 15, 2024
1 parent 25fca33 commit 86211e2
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
4 changes: 2 additions & 2 deletions k8s/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ spec:
resources:
limits:
cpu: "0.50"
memory: "128Mi"
memory: "256Mi"
requests:
cpu: "0.25"
memory: "64Mi"
memory: "128Mi"
14 changes: 14 additions & 0 deletions service/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,20 @@ def index():
)


######################################################################
# HEALTH ENDPOINT FOR K3 CLUSTER
######################################################################
@app.route("/health")
def health():
"""Health endpoint"""
return (
jsonify(
message=status.HTTP_200_OK,
),
status.HTTP_200_OK,
)


######################################################################
# R E S T A P I E N D P O I N T S
######################################################################
Expand Down

0 comments on commit 86211e2

Please sign in to comment.