diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index b3acd2e346..50253186c0 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -11,7 +11,12 @@ // }, // Features to add to the dev container. More info: https://containers.dev/features. - // "features": {}, + "features": { + "ghcr.io/devcontainers/features/node:1": { + "version": "lts" + }, + "ghcr.io/devcontainers/features/docker-in-docker:2": {} + }, // Configure tool-specific properties. "customizations": { @@ -30,7 +35,7 @@ // Use 'forwardPorts' to make a list of ports inside the container available locally. "forwardPorts": [4000], - + "containerEnv": { "LITELLM_LOG": "DEBUG" }, @@ -48,5 +53,5 @@ // "remoteUser": "litellm", // Use 'postCreateCommand' to run commands after the container is created. - "postCreateCommand": "pipx install poetry && poetry install -E extra_proxy -E proxy" + "postCreateCommand": "bash ./.devcontainer/post-create.sh" } \ No newline at end of file diff --git a/.devcontainer/post-create.sh b/.devcontainer/post-create.sh new file mode 100644 index 0000000000..bd72e91a20 --- /dev/null +++ b/.devcontainer/post-create.sh @@ -0,0 +1,17 @@ +#!/usr/bin/env bash +set -e + +echo "[post-create] Installing poetry via pip" +python -m pip install --upgrade pip +python -m pip install poetry + +echo "[post-create] Installing Python dependencies (poetry)" +poetry install --with dev --extras proxy + +echo "[post-create] Generating Prisma client" +poetry run prisma generate + +echo "[post-create] Installing npm dependencies" +cd ui/litellm-dashboard && npm install --no-audit --no-fund + +echo "[post-create] Done" \ No newline at end of file