Welcome to mirror list, hosted at ThFree Co, Russian Federation.

devcontainer.json « .devcontainer - github.com/dotnet/aspnetcore.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 11c94f1b58f374dfc44802f33fa5d7a3a2ac6f8f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
// https://github.com/microsoft/vscode-dev-containers/tree/v0.177.0/containers/dotnet
{
  "name": "C# (.NET)",
  "build": {
    "dockerfile": "Dockerfile",
    "args": {
      // The VARIANT here must align with a dotnet container image that
      // is publicly available on https://mcr.microsoft.com/v2/vscode/devcontainers/dotnet/tags/list.
      // We'll default to `latest` as the default. Generally, the .NET version that is baked
      // into the image by default doesn't matter since we end up installing our own
      // local version and using that by default in the container environment.
      "VARIANT": "latest",
      // Options
      "INSTALL_NODE": "true",
      "NODE_VERSION": "lts/*"
    }
  },
  // Add the IDs of extensions you want installed when the container is created.
  "extensions": [
    "ms-dotnettools.csharp",
    "EditorConfig.EditorConfig",
    "k--kato.docomment",
    "dbaeumer.vscode-eslint"
  ],
  "settings": {
    // Loading projects on demand is better for larger codebases
    "omnisharp.enableMsBuildLoadProjectsOnDemand": true,
    "omnisharp.enableRoslynAnalyzers": true,
    "omnisharp.enableEditorConfigSupport": true,
    "omnisharp.enableImportCompletion": true,
  },
  // Use 'postCreateCommand' to run commands after the container is created.
  "onCreateCommand": "bash -i ${containerWorkspaceFolder}/.devcontainer/scripts/container-creation.sh",
  // Add the locally installed dotnet to the path to ensure that it is activated
  // This is needed so that things like the C# extension can resolve the correct SDK version
  "remoteEnv": {
    "PATH": "${containerWorkspaceFolder}/.dotnet:${containerEnv:PATH}",
    "DOTNET_MULTILEVEL_LOOKUP": "0",
    "TARGET": "net7.0",
    "DOTNET_WATCH_SUPPRESS_LAUNCH_BROWSER": "true"
  },
  // Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
  "remoteUser": "vscode"
}