Unverified Commit 9366ef7e authored by Samruddhi Khandale's avatar Samruddhi Khandale Committed by GitHub

Node: Fix failure when `version:none` (#247)

fix version:none
parent f1c981d0
{ {
"id": "node", "id": "node",
"version": "1.1.0", "version": "1.1.1",
"name": "Node.js (via nvm) and yarn", "name": "Node.js (via nvm) and yarn",
"documentationURL": "https://github.com/devcontainers/features/tree/main/src/node", "documentationURL": "https://github.com/devcontainers/features/tree/main/src/node",
"description": "Installs Node.js, nvm, yarn, and needed dependencies.", "description": "Installs Node.js, nvm, yarn, and needed dependencies.",
......
...@@ -205,6 +205,7 @@ rm -rf /var/lib/apt/lists/* ...@@ -205,6 +205,7 @@ rm -rf /var/lib/apt/lists/*
# Ensure privs are correct for installed node versions. Unfortunately the # Ensure privs are correct for installed node versions. Unfortunately the
# way nvm installs node versions pulls privs from the tar which does not # way nvm installs node versions pulls privs from the tar which does not
# have group write set. We need this when the gid/uid is updated. # have group write set. We need this when the gid/uid is updated.
mkdir -p "${NVM_DIR}/versions"
chmod -R g+rw "${NVM_DIR}/versions" chmod -R g+rw "${NVM_DIR}/versions"
echo "Done!" echo "Done!"
...@@ -16,5 +16,14 @@ ...@@ -16,5 +16,14 @@
"version": "latest" "version": "latest"
} }
} }
},
"version_none": {
"image": "mcr.microsoft.com/devcontainers/base",
"remoteUser": "vscode",
"features": {
"node": {
"version": "none"
}
}
} }
} }
\ No newline at end of file
#!/bin/bash
set -e
# Optional: Import test library
source dev-container-features-test-lib
# Definition specific tests
check "nvm" bash -c ". /usr/local/share/nvm/nvm.sh && nvm install 10"
# Report result
reportResults
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment