Sync sansei branch #1

Merged
Stedos merged 34 commits from sansei into main 2025-02-24 21:12:28 +00:00
2 changed files with 4 additions and 6 deletions
Showing only changes of commit ed57c15387 - Show all commits

View File

@ -5,8 +5,6 @@ ENV PYTHONPATH=/app
WORKDIR /app WORKDIR /app
RUN apt update
COPY requirements.txt ./requirements.txt COPY requirements.txt ./requirements.txt
RUN pip3 install --no-cache-dir -r requirements.txt RUN pip3 install --no-cache-dir -r requirements.txt
@ -21,9 +19,6 @@ RUN sed -i '238s|return \[x for x in arr if lower_limit < x < upper_limit\]|arr_
COPY ./src/ ./src/ COPY ./src/ ./src/
ENV GUNICORN_CMD_ARGS="--bind=0.0.0.0:5000 --workers=16"
WORKDIR /app/src WORKDIR /app/src
# Run gunicorn with the application CMD ["python", "main.py"]
CMD ["sanic", "main", "--port=5000"]

View File

@ -291,3 +291,6 @@ async def process_similarity(request: Request):
except ValueError as e: except ValueError as e:
raise exceptions.BadRequest(str(e)) raise exceptions.BadRequest(str(e))
if __name__ == '__main__':
app.run(host='0.0.0.0', port=5000)