aboutsummaryrefslogtreecommitdiffstats
path: root/app.py
diff options
context:
space:
mode:
authorMichael Grote2023-04-14 12:17:08 +0200
committerMichael Grote2023-04-14 12:17:08 +0200
commitb91cf9fc508a6358ff47a49c11d3cce36bda5432 (patch)
tree128d4e17736992f3d4d00da74936ba0f86b049d1 /app.py
parent2caf356288366a8003dd8e4ba4c2339a9a370653 (diff)
add healthcheck
Diffstat (limited to 'app.py')
-rw-r--r--app.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/app.py b/app.py
index e8e7c6c..cb1cf9d 100644
--- a/app.py
+++ b/app.py
@@ -15,6 +15,10 @@ AUTH_TOKEN = os.environ.get('AUTH_TOKEN', 'myuploadtoken')
def is_valid_filename(filename):
return bool(re.match(VALID_FILENAME_REGEX, filename))
+@app.route('/health', methods=['GET'])
+def health_check():
+ return 'OK'
+
@app.route('/upload', methods=['POST'])
def upload_file():
if 'file' not in request.files: