Skip to content

Commit d971e25

Browse files
authored
Create devcontainer.json
Add devcontainer
1 parent 7a70147 commit d971e25

File tree

1 file changed

+37
-0
lines changed

1 file changed

+37
-0
lines changed

.devcontainer/devcontainer.json

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
2+
// https://github.com/microsoft/vscode-dev-containers/tree/v0.245.0/containers/python-3
3+
{
4+
"name": "python-openai-demos (Ollama)",
5+
"image": "mcr.microsoft.com/devcontainers/python:3.12-bullseye",
6+
"features": {
7+
"ghcr.io/prulloac/devcontainer-features/ollama:1": {}
8+
},
9+
// Configure tool-specific properties.
10+
"customizations": {
11+
// Configure properties specific to VS Code.
12+
"vscode": {
13+
// Set *default* container specific settings.json values on container create.
14+
"settings": {
15+
"python.defaultInterpreterPath": "/usr/local/bin/python"
16+
},
17+
18+
// Add the IDs of extensions you want installed when the container is created.
19+
"extensions": [
20+
"ms-python.python",
21+
"charliermarsh.ruff",
22+
"ms-python.black-formatter"
23+
]
24+
}
25+
},
26+
27+
// Use 'postCreateCommand' to run commands after the container is created.
28+
"postCreateCommand": "pip3 install --user -r requirements-dev.txt && cp .env.sample.ollama .env && ollama run qwen2.5:0.5b",
29+
30+
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
31+
"remoteUser": "vscode",
32+
33+
// Required to handle Ollama models
34+
"hostRequirements": {
35+
"memory": "64gb"
36+
}
37+
}

0 commit comments

Comments
 (0)