devcontainer.json 3.56 KB
Newer Older
1
2
3
{
    "$schema": "https://json-schema.org/draft-07/schema#",
    "copyright": [
4
5
6
7
8
9
10
11
12
13
14
        "SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.",
        "SPDX-License-Identifier: Apache-2.0",
        "Licensed under the Apache License, Version 2.0 (the \"License\");",
        "you may not use this file except in compliance with the License.",
        "You may obtain a copy of the License at",
        "http://www.apache.org/licenses/LICENSE-2.0",
        "Unless required by applicable law or agreed to in writing, software",
        "distributed under the License is distributed on an \"AS IS\" BASIS,",
        "WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.",
        "See the License for the specific language governing permissions and",
        "limitations under the License."
15
16
    ],
    "name": "NVIDIA Dynamo Development",
17
18
19
    "remoteUser": "ubuntu", // Matches our container user
    "updateRemoteUserUID": true, // Updates the UID of the remote user to match the host user, avoids permission errors
    "image": "dynamo:latest-vllm-local-dev", // Use the latest VLLM local dev image
20
    "runArgs": [
21
22
23
24
25
26
27
        "--gpus=all",
        "--network=host",
        "--ipc=host",
        "--cap-add=SYS_PTRACE",
        "--shm-size=10G",
        "--ulimit=memlock=-1",
        "--ulimit=stack=67108864"
28
    ],
29
    "service": "dynamo",
30
31
32
33
    "customizations": {
        "vscode": {
            "extensions": [
                "ms-python.python",
34
35
36
                "ms-python.pylint",
                "ms-python.vscode-pylance",
                "rust-lang.rust-analyzer"
37
38
            ],
            "settings": {
39
40
41
42
                "terminal.integrated.defaultProfile.linux": "bash",
                "terminal.integrated.cwd": "/home/ubuntu/dynamo",

                "python.defaultInterpreterPath": "/opt/dynamo/venv/bin/python",
43
44
                "python.linting.enabled": true,
                "python.linting.pylintEnabled": true,
45
46
47
48
49
50
51
52
53

                "rust-analyzer.checkOnSave.command": "clippy",
                "rust-analyzer.checkOnSave.enable": true,
                "rust-analyzer.semanticHighlighting.enable": true,

                "editor.semanticHighlighting.enabled": true,

                "files.trimTrailingWhitespace": true,
                "files.insertFinalNewline": true
54
55
56
            }
        }
    },
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
    "workspaceFolder": "/home/ubuntu",
    "workspaceMount": "source=${localWorkspaceFolder},target=/home/ubuntu/dynamo,type=bind,consistency=cached",
    "userEnvProbe": "interactiveShell",
    "postCreateCommand": "/bin/bash /home/ubuntu/dynamo/.devcontainer/post-create.sh", // Runs cargo build and pip installs packages
    "containerEnv": {
        "GITHUB_TOKEN": "${localEnv:GITHUB_TOKEN}",
        "HF_TOKEN": "${localEnv:HF_TOKEN}",
        "CARGO_HOME": "/home/ubuntu/dynamo/.build/.cargo",
        "RUSTUP_HOME": "/home/ubuntu/dynamo/.build/.rustup"
    },
    "mounts": [
        // Uncomment for additional functionality
        "source=${localEnv:HF_HOME},target=/home/ubuntu/.cache/huggingface,type=bind", // Uncomment to enable HF Cache Mount. Make sure to set HF_HOME env var in you .bashrc
        "source=${localEnv:HOME}/.ssh,target=/home/ubuntu/.ssh,type=bind", // Uncomment to enable SSH Mount, note the .gitconfig should already by copied in

        // Default mounts
        "source=/tmp/,target=/tmp/,type=bind",
        "source=dynamo-bashhistory,target=/home/ubuntu/.commandhistory,type=volume", // For bash history
        "source=dynamo-precommit-cache,target=/home/ubuntu/.cache/pre-commit,type=volume"  // For pre-commit cache
    ]
}