update docker
working process on server utilize ~200 Mb RAM
This commit is contained in:
+3
-14
@@ -1,22 +1,11 @@
|
||||
services:
|
||||
backend:
|
||||
image: python:3.12-alpine
|
||||
build: .
|
||||
container_name: uvpn-backend
|
||||
working_dir: /app
|
||||
volumes:
|
||||
- .:/app
|
||||
- /app/.venv
|
||||
environment:
|
||||
- UV_COMPILE_BYTECODE=1
|
||||
- UV_LINK_MODE=copy
|
||||
expose:
|
||||
- 8000
|
||||
command: >
|
||||
sh -c "pip install --no-cache-dir uv &&
|
||||
uv sync --frozen --no-dev &&
|
||||
uv run uvicorn main:app --host 0.0.0.0 --port 8000 --reload"
|
||||
networks:
|
||||
- remnawave-network
|
||||
- remnawave-network
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8000/api/v1/health', timeout=3).read()"]
|
||||
@@ -27,4 +16,4 @@ services:
|
||||
|
||||
networks:
|
||||
remnawave-network:
|
||||
external: true
|
||||
external: true
|
||||
|
||||
Reference in New Issue
Block a user