Update to 0.134.0 version of definition

This commit is contained in:
Chuck Lantz
2020-08-11 13:12:01 -07:00
parent 5b259171f1
commit 8bb6eeb538
2 changed files with 33 additions and 51 deletions

View File

@@ -1,37 +1,14 @@
#------------------------------------------------------------------------------------------------------------- # See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/v0.134.0/containers/javascript-node/.devcontainer/base.Dockerfile
# Copyright (c) Microsoft Corporation. All rights reserved. ARG VARIANT="14"
# Licensed under the MIT License. See https://go.microsoft.com/fwlink/?linkid=2090316 for license information. FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-${VARIANT}
#-------------------------------------------------------------------------------------------------------------
# To fully customize the contents of this image, use the following Dockerfile instead: # [Optional] Uncomment this section to install additional OS packages.
# https://github.com/microsoft/vscode-dev-containers/tree/v0.112.0/containers/javascript-node-12/.devcontainer/Dockerfile # RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-12 # && apt-get -y install --no-install-recommends <your-package-list-here>
# The image referenced above includes a non-root user with sudo access. Add # [Optional] Uncomment if you want to install an additional version of node using nvm
# the "remoteUser" property to devcontainer.json to use it. On Linux, the container # ARG EXTRA_NODE_VERSION=10
# user's GID/UIDs will be updated to match your local UID/GID when using the image # RUN su node -c "source /usr/local/share/nvm/nvm.sh && nvm install ${EXTRA_NODE_VERSION}"
# or dockerFile property. Update USER_UID/USER_GID below if you are using the
# dockerComposeFile property or want the image itself to start with different ID
# values. See https://aka.ms/vscode-remote/containers/non-root-user for details.
ARG USER_UID=1000
ARG USER_GID=$USER_UID
ARG USERNAME=node
# [Optional] Update UID/GID if needed # [Optional] Uncomment if you want to install more global node modules
RUN if [ "$USER_GID" != "1000" ] || [ "$USER_UID" != "1000" ]; then \ # RUN sudo -u node npm install -g <your-package-list-here>
groupmod --gid $USER_GID $USERNAME \
&& usermod --uid $USER_UID --gid $USER_GID $USERNAME \
&& chown -R $USER_UID:$USER_GID /home/$USERNAME; \
fi
# ** [Optional] Uncomment this section to install additional packages. **
#
# ENV DEBIAN_FRONTEND=noninteractive
# RUN apt-get update \
# && apt-get -y install --no-install-recommends <your-package-list-here> \
# #
# # Clean up
# && apt-get autoremove -y \
# && apt-get clean -y \
# && rm -rf /var/lib/apt/lists/*
# ENV DEBIAN_FRONTEND=dialog

View File

@@ -1,24 +1,29 @@
// For format details, see https://aka.ms/vscode-remote/devcontainer.json or this file's README at:
// https://github.com/microsoft/vscode-dev-containers/tree/v0.134.0/containers/javascript-node
{ {
"name": "Node.js Sample", "name": "Node.js",
"dockerFile": "Dockerfile", "build": {
"dockerfile": "Dockerfile",
// Update 'VARIANT' to pick a Node version: 10, 12, 14
"args": { "VARIANT": "12" }
},
// Use 'settings' to set *default* container specific settings.json values on container create. // Set *default* container specific settings.json values on container create.
"settings": { "settings": {
"terminal.integrated.shell.linux": "/bin/bash" "terminal.integrated.shell.linux": "/bin/bash"
}, },
// Add the IDs of extensions you want installed when the container is created in the array below. // Add the IDs of extensions you want installed when the container is created.
"extensions": [ "extensions": [
"dbaeumer.vscode-eslint" "dbaeumer.vscode-eslint"
], ],
// Use 'forwardPorts' to make a list of ports inside the container available locally. // Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [3000], "forwardPorts": [3000],
// Specifies a command that should be run after the container has been created. // Specifies a command that should be run after the container has been created.
"postCreateCommand": "yarn install", "postCreateCommand": "yarn install",
// Comment out the next line to run as root instead.
"remoteUser": "node"
// Comment out the next line to run as root instead.
"remoteUser": "node"
} }