|
| 1 | +// For format details, see https://aka.ms/devcontainer.json. For config options, see the |
| 2 | +// README at: https://github.com/devcontainers/templates/tree/main/src/python |
| 3 | +{ |
| 4 | + "name": "Example", |
| 5 | + // Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile |
| 6 | + "dockerComposeFile": "./docker-compose.yaml", |
| 7 | + "service": "example", |
| 8 | + "workspaceFolder": "/example", |
| 9 | + "shutdownAction": "stopCompose", |
| 10 | + "forwardPorts": [ |
| 11 | + 8002 |
| 12 | + ], |
| 13 | + "customizations": { |
| 14 | + "vscode": { |
| 15 | + "extensions": [ |
| 16 | + "vivaxy.vscode-conventional-commits", |
| 17 | + "ms-toolsai.datawrangler", |
| 18 | + "mikestead.dotenv", |
| 19 | + "elagil.pre-commit-helper", |
| 20 | + "donjayamanne.python-extension-pack", |
| 21 | + "charliermarsh.ruff", |
| 22 | + "sourcery.sourcery", // Remove sourcery and sonarlint if you have less memory |
| 23 | + "SonarSource.sonarlint-vscode", |
| 24 | + "redhat.vscode-yaml", |
| 25 | + "ms-azuretools.vscode-docker", |
| 26 | + "ms-toolsai.jupyter" |
| 27 | + ], |
| 28 | + "settings": { |
| 29 | + "[python]": { |
| 30 | + "editor.formatOnType": false, |
| 31 | + "editor.codeActionsOnSave": { |
| 32 | + "source.organizeImports.ruff": "explicit", |
| 33 | + "source.fixAll": "explicit", |
| 34 | + "source.formatDocument": "always" |
| 35 | + } |
| 36 | + }, |
| 37 | + "files.watcherExclude": { |
| 38 | + "**/.git/objects/**": true, |
| 39 | + "**/.git/subtree-cache/**": true, |
| 40 | + "**/.hg/store/**": true, |
| 41 | + "**/.pytest_cache/**": true, |
| 42 | + "**/.ruff_cache/**": true, |
| 43 | + "**/__pycache__/**": true, |
| 44 | + "./data/**": true, |
| 45 | + } |
| 46 | + } |
| 47 | + } |
| 48 | + }, |
| 49 | + "remoteUser": "root", |
| 50 | + "containerUser": "root", |
| 51 | + "postCreateCommand": "mkdir .vscode -p && cp /example/.devcontainer/container-launch.json .vscode/launch.json && pre-commit install -t pre-commit && pre-commit install-hooks", |
| 52 | + "features": { |
| 53 | + "ghcr.io/jsburckhardt/devcontainer-features/ruff:1": {}, |
| 54 | + "ghcr.io/jsburckhardt/devcontainer-features/uv:1": {} |
| 55 | + } |
| 56 | + // Features to add to the dev container. More info: https://containers.dev/features. |
| 57 | + // "features": {}, |
| 58 | + // Use 'forwardPorts' to make a list of ports inside the container available locally. |
| 59 | + // "forwardPorts": [], |
| 60 | + // Use 'postCreateCommand' to run commands after the container is created. |
| 61 | + // "postCreateCommand": "pip3 install --user -r requirements.txt", |
| 62 | + // Configure tool-specific properties. |
| 63 | + // "customizations": {}, |
| 64 | + // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. |
| 65 | + // "remoteUser": "root" |
| 66 | +} |
0 commit comments