Skip to content

Commit

Permalink
add nvm install command to install correct node version (#344)
Browse files Browse the repository at this point in the history
* add nvm install command to install correct node version

* update command

* move start command

* Update devcontainer.json
  • Loading branch information
Adammatthiesen authored Oct 6, 2024
1 parent 52fcafe commit c50379a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ FROM mcr.microsoft.com/devcontainers/javascript-node:0-20

# We uninstall pnpm here, since we enable the corepack version in the postCreateCommand
# This ensures we respect the "packageManager" version in package.json
RUN npm uninstall -g pnpm
RUN npm uninstall -g pnpm && nvm install 20.14.0

COPY welcome-message.txt /usr/local/etc/vscode-dev-containers/first-run-notice.txt
6 changes: 1 addition & 5 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,8 @@
"build": {
"dockerfile": "Dockerfile"
},

"postCreateCommand": "sudo corepack enable pnpm && pnpm config set store-dir /home/node/.pnpm-store && PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=1 pnpm install",

"waitFor": "postCreateCommand",

"customizations": {
"codespaces": {
"openFiles": ["README.md"]
Expand All @@ -18,8 +15,7 @@
"astro-build.houston",
"biomejs.biome",
"eamodio.gitlens",
"redhat.vscode-yaml",
"ZainChen.json"
"redhat.vscode-yaml"
]
}
}
Expand Down

0 comments on commit c50379a

Please sign in to comment.