|
1 | | -// For format details, see https://aka.ms/vscode-remote/devcontainer.json or this file's README at: |
2 | | -// https://github.com/microsoft/vscode-dev-containers/tree/v0.202.3/containers/python-3 |
| 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 | 3 | { |
4 | 4 | "name": "Python 3", |
5 | | -"build": { |
6 | | -"dockerfile": "Dockerfile", |
7 | | -"context": "..", |
8 | | -"args": { |
9 | | -// Update 'VARIANT' to pick a Python version: 3, 3.9, 3.8, 3.7, 3.6. |
10 | | -// Append -bullseye or -buster to pin to an OS version. |
11 | | -// Use -bullseye variants on local on arm64/Apple Silicon. |
12 | | -"VARIANT": "3.9-bullseye", |
13 | | -// Options |
14 | | -"NODE_VERSION": "lts/*" |
15 | | -} |
16 | | -}, |
17 | | - |
| 5 | +// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile |
| 6 | +"image": "mcr.microsoft.com/devcontainers/python:0-3.11", |
| 7 | + |
| 8 | +// Features to add to the dev container. More info: https://containers.dev/features. |
| 9 | +// "features": {}, |
| 10 | + |
18 | 11 | // Configure tool-specific properties. |
19 | 12 | "customizations": { |
20 | 13 | // Configure properties specific to VS Code. |
21 | 14 | "vscode": { |
22 | | -// Set *default* container specific settings.json values on container create. |
23 | | -"settings": { |
24 | | -"terminal.integrated.profiles.linux": { |
25 | | -"bash": { |
26 | | -"path": "/bin/bash" |
27 | | -} |
28 | | -}, |
29 | | -"python.defaultInterpreterPath": "/usr/local/bin/python", |
30 | | -"python.languageServer": "Default", |
31 | | -"python.linting.enabled": true, |
32 | | -"python.linting.pylintEnabled": true, |
33 | | -"python.formatting.autopep8Path": "/usr/local/py-utils/bin/autopep8", |
34 | | -"python.formatting.blackPath": "/usr/local/py-utils/bin/black", |
35 | | -"python.formatting.yapfPath": "/usr/local/py-utils/bin/yapf", |
36 | | -"python.linting.banditPath": "/usr/local/py-utils/bin/bandit", |
37 | | -"python.linting.flake8Path": "/usr/local/py-utils/bin/flake8", |
38 | | -"python.linting.mypyPath": "/usr/local/py-utils/bin/mypy", |
39 | | -"python.linting.pycodestylePath": "/usr/local/py-utils/bin/pycodestyle", |
40 | | -"python.linting.pydocstylePath": "/usr/local/py-utils/bin/pydocstyle", |
41 | | -"python.linting.pylintPath": "/usr/local/py-utils/bin/pylint" |
42 | | -}, |
43 | | - |
44 | | -// Add the IDs of extensions you want installed when the container is created. |
| 15 | +"settings": {}, |
45 | 16 | "extensions": [ |
46 | | -"ms-python.python", |
47 | | -"ms-python.vscode-pylance" |
| 17 | +"streetsidesoftware.code-spell-checker" |
48 | 18 | ] |
49 | 19 | } |
50 | 20 | }, |
51 | | - |
| 21 | +
|
52 | 22 | // Use 'forwardPorts' to make a list of ports inside the container available locally. |
53 | 23 | // "forwardPorts": [9000], |
54 | 24 |
|
55 | | -// Use 'portsAttributes' to set default properties for specific forwarded ports. More info: https://code.visualstudio.com/docs/remote/devcontainerjson-reference. |
| 25 | +// Use 'portsAttributes' to set default properties for specific forwarded ports. |
| 26 | +// More info: https://containers.dev/implementors/json_reference/#port-attributes |
56 | 27 | "portsAttributes": { |
57 | 28 | "9000": { |
58 | 29 | "label": "Hello Remote World", |
59 | 30 | "onAutoForward": "notify" |
60 | 31 | } |
61 | 32 | }, |
62 | 33 |
|
63 | | -// Use 'otherPortsAttributes' to configure any ports that aren't configured using 'portsAttributes'. |
64 | | -// "otherPortsAttributes": { |
65 | | -// "onAutoForward": "silent" |
66 | | -// }, |
67 | | - |
68 | 34 | // Use 'postCreateCommand' to run commands after the container is created. |
69 | | -"postCreateCommand": "pip3 install -r requirements.txt", |
| 35 | +"postCreateCommand": "pip3 install -r requirements.txt" |
70 | 36 |
|
71 | | -// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root. |
72 | | -"remoteUser": "vscode" |
| 37 | +// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. |
| 38 | +// "remoteUser": "root" |
73 | 39 | } |
0 commit comments