mirror of
https://github.com/wled/WLED.git
synced 2025-07-19 08:46:34 +00:00
Fix devcontainer
This commit is contained in:
parent
a2d84886c0
commit
1a82a3bf7b
@ -2,12 +2,7 @@
|
|||||||
|
|
||||||
# [Choice] Python version: 3, 3.9, 3.8, 3.7, 3.6
|
# [Choice] Python version: 3, 3.9, 3.8, 3.7, 3.6
|
||||||
ARG VARIANT="3"
|
ARG VARIANT="3"
|
||||||
FROM mcr.microsoft.com/vscode/devcontainers/python:0-${VARIANT}
|
FROM mcr.microsoft.com/devcontainers/python:0-${VARIANT}
|
||||||
|
|
||||||
# [Option] Install Node.js
|
|
||||||
ARG INSTALL_NODE="true"
|
|
||||||
ARG NODE_VERSION="lts/*"
|
|
||||||
RUN if [ "${INSTALL_NODE}" = "true" ]; then su vscode -c "source /usr/local/share/nvm/nvm.sh && nvm install ${NODE_VERSION} 2>&1"; fi
|
|
||||||
|
|
||||||
# [Optional] If your pip requirements rarely change, uncomment this section to add them to the image.
|
# [Optional] If your pip requirements rarely change, uncomment this section to add them to the image.
|
||||||
# COPY requirements.txt /tmp/pip-tmp/
|
# COPY requirements.txt /tmp/pip-tmp/
|
||||||
|
@ -5,10 +5,7 @@
|
|||||||
"context": "..",
|
"context": "..",
|
||||||
"args": {
|
"args": {
|
||||||
// Update 'VARIANT' to pick a Python version: 3, 3.6, 3.7, 3.8, 3.9
|
// Update 'VARIANT' to pick a Python version: 3, 3.6, 3.7, 3.8, 3.9
|
||||||
"VARIANT": "3",
|
"VARIANT": "3"
|
||||||
// Options
|
|
||||||
"INSTALL_NODE": "true",
|
|
||||||
"NODE_VERSION": "lts/*"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -54,7 +51,7 @@
|
|||||||
// "forwardPorts": [],
|
// "forwardPorts": [],
|
||||||
|
|
||||||
// Use 'postCreateCommand' to run commands after the container is created.
|
// Use 'postCreateCommand' to run commands after the container is created.
|
||||||
"postCreateCommand": "npm install",
|
"postCreateCommand": "bash -i -c 'nvm install && npm ci'",
|
||||||
|
|
||||||
// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
|
// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
|
||||||
"remoteUser": "vscode"
|
"remoteUser": "vscode"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user