1
0
mirror of https://github.com/immich-app/immich.git synced 2025-04-25 13:24:51 +02:00
Mert 84c35e35d6
chore(ml): installable package (#17153)
* app -> immich_ml

* fix test ci

* omit file name

* add new line

* add new line
2025-03-27 19:49:09 +00:00

15 lines
277 B
Python

import os
import sys
import requests
port = os.getenv("IMMICH_PORT", 3003)
try:
response = requests.get(f"http://localhost:{port}/ping", timeout=2)
if response.status_code == 200:
sys.exit(0)
sys.exit(1)
except requests.RequestException:
sys.exit(1)