v.0.11.1 --network=dev-network for conatiners

This commit is contained in:
tiijay
2025-11-21 11:31:07 +00:00
parent 2233be7987
commit 3a8fb95f4f
5 changed files with 45 additions and 16 deletions

View File

@@ -6,6 +6,10 @@
"build": {
"dockerfile": "Dockerfile"
},
"runArgs": [
"--network=dev-network",
"--name=api-server"
],
// "image": "mcr.microsoft.com/devcontainers/python:1-3.12",
// "image": "python:latest",
//"image": "python:3.13-slim",
@@ -37,8 +41,9 @@
}
},
// Use 'postCreateCommand' to run commands after the container is created.
"postCreateCommand": "uv sync"
"postCreateCommand": "uv sync",
// "postCreateCommand": "apt-get update && apt-get install -y git && pip3 install -r requirements.txt"
"postStartCommand": "uv run app/main.py" // Add this line
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}