Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
devcontainer-features
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
eazydevelop-devcontainer-temp
devcontainer-features
Commits
2d89dc30
Unverified
Commit
2d89dc30
authored
Oct 06, 2022
by
Samruddhi Khandale
Committed by
GitHub
Oct 06, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Node: Fix nvm ownership (#199)
* Node: Fix nvm ownership * remove 0002
parent
a9441adf
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
2 deletions
+5
-2
devcontainer-feature.json
src/node/devcontainer-feature.json
+1
-1
install.sh
src/node/install.sh
+3
-1
test.sh
test/node/test.sh
+1
-0
No files found.
src/node/devcontainer-feature.json
View file @
2d89dc30
{
{
"id"
:
"node"
,
"id"
:
"node"
,
"version"
:
"1.0.
5
"
,
"version"
:
"1.0.
6
"
,
"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."
,
...
...
src/node/install.sh
View file @
2d89dc30
...
@@ -120,7 +120,7 @@ umask 0002
...
@@ -120,7 +120,7 @@ umask 0002
usermod
-a
-G
nvm
${
USERNAME
}
usermod
-a
-G
nvm
${
USERNAME
}
mkdir
-p
${
NVM_DIR
}
mkdir
-p
${
NVM_DIR
}
chown
"
${
USERNAME
}
:nvm"
${
NVM_DIR
}
chown
"
${
USERNAME
}
:nvm"
${
NVM_DIR
}
chmod
g+s
${
NVM_DIR
}
chmod
-R
g+r+w
${
NVM_DIR
}
su
${
USERNAME
}
-c
"
$(
cat
<<
EOF
su
${
USERNAME
}
-c
"
$(
cat
<<
EOF
set -e
set -e
umask 0002
umask 0002
...
@@ -185,4 +185,6 @@ if [ "${INSTALL_TOOLS_FOR_NODE_GYP}" = "true" ]; then
...
@@ -185,4 +185,6 @@ if [ "${INSTALL_TOOLS_FOR_NODE_GYP}" = "true" ]; then
fi
fi
fi
fi
find
"
${
NVM_DIR
}
"
-type
d
-print0
| xargs
-n
1
-0
chmod
g+s
echo
"Done!"
echo
"Done!"
test/node/test.sh
View file @
2d89dc30
...
@@ -7,6 +7,7 @@ source dev-container-features-test-lib
...
@@ -7,6 +7,7 @@ source dev-container-features-test-lib
# Definition specific tests
# Definition specific tests
check
"version"
node
--version
check
"version"
node
--version
check
"nvm"
bash
-c
". /usr/local/share/nvm/nvm.sh && nvm install 10"
# Report result
# Report result
reportResults
reportResults
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment