Skip to content

Commit 42d6fc6

Browse files
Merge branch 'master' into pre-release/1.0.7
2 parents 78f1f4e + 8adc390 commit 42d6fc6

60 files changed

Lines changed: 2385 additions & 776 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.config/dotnet-tools.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@
33
"isRoot": true,
44
"tools": {
55
"dotnet-reportgenerator-globaltool": {
6-
"version": "4.6.1",
6+
"version": "5.4.5",
77
"commands": [
88
"reportgenerator"
9-
]
9+
],
10+
"rollForward": false
1011
}
1112
}
1213
}

.devcontainer/Dockerfile

Lines changed: 15 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -1,85 +1,15 @@
1-
#-------------------------------------------------------------------------------------------------------------
2-
# Copyright (c) Microsoft Corporation. All rights reserved.
3-
# Licensed under the MIT License. See https://go.microsoft.com/fwlink/?linkid=2090316 for license information.
4-
#-------------------------------------------------------------------------------------------------------------
5-
6-
FROM mcr.microsoft.com/dotnet/core/sdk:3.1
7-
8-
# This Dockerfile adds a non-root user with sudo access. Use the "remoteUser"
9-
# property in devcontainer.json to use it. On Linux, the container user's GID/UIDs
10-
# will be updated to match your local UID/GID (when using the dockerFile property).
11-
# See https://aka.ms/vscode-remote/containers/non-root-user for details.
12-
ARG USERNAME=vscode
13-
ARG USER_UID=1000
14-
ARG USER_GID=$USER_UID
15-
16-
# [Optional] Version of Node.js to install.
17-
ARG INSTALL_NODE="true"
18-
ARG NODE_VERSION="lts/*"
19-
ENV NVM_DIR=/home/vscode/.nvm
20-
21-
# [Optional] Install the Azure CLI
22-
ARG INSTALL_AZURE_CLI="false"
23-
24-
# Avoid warnings by switching to noninteractive
25-
ENV DEBIAN_FRONTEND=noninteractive
26-
27-
# Configure apt and install packages
28-
RUN apt-get update \
29-
&& apt-get -y install --no-install-recommends apt-utils dialog 2>&1 \
30-
#
31-
# Verify git, process tools, lsb-release (common in install instructions for CLIs) installed
32-
&& apt-get -y install git openssh-client less iproute2 procps apt-transport-https gnupg2 curl lsb-release \
33-
#
34-
# Create a non-root user to use if preferred - see https://aka.ms/vscode-remote/containers/non-root-user.
35-
&& groupadd --gid $USER_GID $USERNAME \
36-
&& useradd -s /bin/bash --uid $USER_UID --gid $USER_GID -m $USERNAME \
37-
# [Optional] Add sudo support for the non-root user
38-
&& apt-get install -y sudo \
39-
&& echo $USERNAME ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/$USERNAME\
40-
&& chmod 0440 /etc/sudoers.d/$USERNAME \
41-
#
42-
# Add vscode folders to prevent re-installs
43-
&& mkdir -p /home/$USERNAME/.vscode-server/extensions \
44-
/home/$USERNAME/.vscode-server-insiders/extensions \
45-
&& chown -R $USERNAME \
46-
/home/$USERNAME/.vscode-server \
47-
/home/$USERNAME/.vscode-server-insiders \
48-
#
49-
# [Optional] Install Node.js for ASP.NET Core Web Applicationss
50-
&& if [ "$INSTALL_NODE" = "true" ]; then \
51-
#
52-
# Install nvm and Node
53-
mkdir ${NVM_DIR} \
54-
&& curl -so- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh | bash 2>&1 \
55-
&& chown -R vscode:vscode ${NVM_DIR} \
56-
&& /bin/bash -c "source $NVM_DIR/nvm.sh \
57-
&& nvm install ${NODE_VERSION} \
58-
&& nvm alias default ${NODE_VERSION}" 2>&1 \
59-
&& INIT_STRING='[ -s "$NVM_DIR/nvm.sh" ] && \\. "$NVM_DIR/nvm.sh" && [ -s "$NVM_DIR/bash_completion" ] && \\. "$NVM_DIR/bash_completion"' \
60-
&& echo $INIT_STRING >> /home/vscode/.bashrc \
61-
&& echo $INIT_STRING >> /home/vscode/.zshrc \
62-
&& echo $INIT_STRING >> /root/.zshrc \
63-
#
64-
# Install yarn
65-
&& curl -sS https://dl.yarnpkg.com/$(lsb_release -is | tr '[:upper:]' '[:lower:]')/pubkey.gpg | apt-key add - 2>/dev/null \
66-
&& echo "deb https://dl.yarnpkg.com/$(lsb_release -is | tr '[:upper:]' '[:lower:]')/ stable main" | tee /etc/apt/sources.list.d/yarn.list \
67-
&& apt-get update \
68-
&& apt-get -y install --no-install-recommends yarn; \
69-
fi \
70-
#
71-
# [Optional] Install the Azure CLI
72-
&& if [ "$INSTALL_AZURE_CLI" = "true" ]; then \
73-
echo "deb [arch=amd64] https://packages.microsoft.com/repos/azure-cli/ $(lsb_release -cs) main" > /etc/apt/sources.list.d/azure-cli.list \
74-
&& curl -sL https://packages.microsoft.com/keys/microsoft.asc | apt-key add - 2>/dev/null \
75-
&& apt-get update \
76-
&& apt-get install -y azure-cli; \
77-
fi \
78-
#
79-
# Clean up
80-
&& apt-get autoremove -y \
81-
&& apt-get clean -y \
82-
&& rm -rf /var/lib/apt/lists/*
83-
84-
# Switch back to dialog for any ad-hoc use of apt-get
85-
ENV DEBIAN_FRONTEND=dialog
1+
FROM mcr.microsoft.com/devcontainers/base:alpine
2+
ENV PATH $PATH:/home/vscode/.dotnet:/home/vscode/.dotnet/tools
3+
4+
ARG VARIANT
5+
RUN if [ "${VARIANT#*noble}" != "$VARIANT" ]; then \
6+
if id "ubuntu" &>/dev/null; then \
7+
echo "Deleting user 'ubuntu' for $VARIANT" && userdel -f -r ubuntu || echo "Failed to delete ubuntu user for $VARIANT"; \
8+
else \
9+
echo "User 'ubuntu' does not exist for $VARIANT"; \
10+
fi; \
11+
fi
12+
13+
# clear this environment variable so xml docs from NuGet packages are unpackaged. The default dotnet/sdk image sets it to 'skip'.
14+
# see https://github.com/dotnet/dotnet-docker/issues/2790
15+
ENV NUGET_XMLDOC_MODE=

.devcontainer/devcontainer.json

Lines changed: 39 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,48 @@
11
// For format details, see https://aka.ms/vscode-remote/devcontainer.json or this file's README at:
22
// https://github.com/microsoft/vscode-dev-containers/tree/v0.117.1/containers/dotnetcore-3.1
33
{
4-
"name": "C# (.NET Core 3.1)",
5-
"dockerFile": "Dockerfile",
6-
// Set *default* container specific settings.json values on container create.
7-
"settings": {
8-
"terminal.integrated.shell.linux": "/bin/bash"
4+
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
5+
"features": {
6+
"ghcr.io/devcontainers/features/dotnet:2": {
7+
"additionalVersions": "lts"
8+
}
9+
},
10+
"customizations": {
11+
// Set *default* container specific settings.json values on container create.
12+
"settings": {
13+
"omnisharp.enableMsBuildLoadProjectsOnDemand": true,
14+
"omnisharp.enableRoslynAnalyzers": true,
15+
"omnisharp.enableEditorConfigSupport": true,
16+
"omnisharp.enableImportCompletion": true
17+
},
18+
// Configure properties specific to VS Code.
19+
"vscode": {
20+
// Add the IDs of extensions you want installed when the container is created.
21+
"extensions": [
22+
"github.vscode-github-actions",
23+
"ms-dotnettools.csdevkit",
24+
"EditorConfig.EditorConfig",
25+
"dbaeumer.vscode-eslint"
26+
]
27+
}
928
},
10-
// Add the IDs of extensions you want installed when the container is created.
11-
"extensions": [
12-
"editorconfig.editorconfig",
13-
"jchannon.csharpextensions",
14-
"k--kato.docomment",
15-
"ms-dotnettools.csharp"
16-
],
17-
// Use 'forwardPorts' to make a list of ports inside the container available locally.
18-
// "forwardPorts": [5000, 5001],
19-
// [Optional] To reuse of your local HTTPS dev cert, first export it locally using this command:
20-
// * Windows PowerShell:
21-
// dotnet dev-certs https --trust; dotnet dev-certs https -ep "$env:USERPROFILE/.aspnet/https/aspnetapp.pfx" -p "SecurePwdGoesHere"
22-
// * macOS/Linux terminal:
23-
// dotnet dev-certs https --trust; dotnet dev-certs https -ep "${HOME}/.aspnet/https/aspnetapp.pfx" -p "SecurePwdGoesHere"
24-
//
25-
// Next, after running the command above, uncomment lines in the 'mounts' and 'remoteEnv' lines below,
26-
// and open / rebuild the container so the settings take effect.
27-
//
28-
"remoteUser": "vscode",
2929
"mounts": [
30-
"source=vscode-extensions,target=/home/vscode/.vscode-server/extensions,type=volume",
31-
// And/or for VS Code Insiders
32-
"source=vscode-insiders,target=/home/vscode/.vscode-server-insiders/extensions,type=volume",
30+
// user profile
31+
"source=profile,target=/home/vscode,type=volume",
32+
// vscode extensions
33+
"target=/vscode/.vscode-server,type=volume",
34+
// bash history
35+
//"source=dddseed-bashhistory,target=/commandhistory,type=volume"
36+
// ssh config for git
37+
"source=${localEnv:HOME}${localEnv:USERPROFILE}/.ssh/,target=/home/vscode/.ssh,type=bind,consistency=cached"
38+
// personal NuGet.Config for any api keys
39+
//"source=${localEnv:APPDATA}/NuGet/NuGet.config,target=/home/vscode/.nuget/NuGet/NuGet.Config,type=bind,consistency=cached"
3340
],
3441
"remoteEnv": {
35-
// "ASPNETCORE_Kestrel__Certificates__Default__Password": "SecurePwdGoesHere",
36-
// "ASPNETCORE_Kestrel__Certificates__Default__Path": "/home/vscode/.aspnet/https/aspnetapp.pfx",
42+
// move Nuget global packages store to a directory where user vscode has write access
43+
// because the NuGet.Config mount below is mounted as readonly
44+
// "NUGET_PACKAGES": "/home/vscode/.cache/nuget/packages"
3745
},
38-
//"postCreateCommand": "sudo chown vscode dotnet"
46+
//"postCreateCommand": "dotnet restore",
47+
"remoteUser": "vscode"
3948
}

0 commit comments

Comments
 (0)