Skip to content

Commit

Permalink
chore(docker): Upgrade Node.js to version 20
Browse files Browse the repository at this point in the history
Use the current LTS version for `Node.js` in `.versions` and in
`Dockerfile`. When that version is installed via `nvm`, in Dockerfile,
Npm version 10.1.0 is installed.

So, also upgrade the Npm to that version.

Signed-off-by: Frank Viernau <frank_viernau@epam.com>
  • Loading branch information
fviernau committed Nov 1, 2023
1 parent e082ad3 commit e2ed458
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .versions
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ GO_DEP_VERSION=0.5.4
GO_VERSION=1.21.1
HASKELL_STACK_VERSION=2.7.5
JAVA_VERSION=17
NODEJS_VERSION=18.17.1
NPM_VERSION=8.15.1
NODEJS_VERSION=20.9.0
NPM_VERSION=10.1.0
NUGET_INSPECTOR_VERSION=0.9.12
PHP_VERSION=8.1
PIPTOOL_VERSION=22.2.2
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,8 @@ COPY --from=pythonbuild /opt/python /opt/python
FROM base AS nodejsbuild

ARG BOWER_VERSION=1.8.12
ARG NODEJS_VERSION=18.14.2
ARG NPM_VERSION=8.15.1
ARG NODEJS_VERSION=20.9.0
ARG NPM_VERSION=10.1.0
ARG PNPM_VERSION=8.8.0
ARG YARN_VERSION=1.22.17

Expand Down
4 changes: 2 additions & 2 deletions Dockerfile-legacy
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ ENV \
GO_DEP_VERSION=0.5.4 \
GO_VERSION=1.21.1 \
HASKELL_STACK_VERSION=2.7.5 \
NPM_VERSION=8.15.1 \
NPM_VERSION=10.1.0 \
PNPM_VERSION=8.8.0 \
PYTHON_PIPENV_VERSION=2022.9.24 \
PYTHON_POETRY_VERSION=1.6.1 \
Expand All @@ -100,7 +100,7 @@ RUN --mount=type=cache,target=/var/cache/apt --mount=type=cache,target=/var/lib/
echo "deb https://repo.scala-sbt.org/scalasbt/debian all main" | tee -a /etc/apt/sources.list.d/sbt.list && \
curl -ksS "https://keyserver.ubuntu.com/pks/lookup?op=get&options=mr&search=0x2EE0EA64E40A89B84B2DF73499E82A75642AC823" | apt-key adv --import - && \
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_18.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \
add-apt-repository -y ppa:git-core/ppa && \
apt-get update && \
apt-get install -y --no-install-recommends \
Expand Down
2 changes: 1 addition & 1 deletion plugins/package-managers/node/src/main/kotlin/Npm.kt
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ open class Npm(

override fun command(workingDir: File?) = if (Os.isWindows) "npm.cmd" else "npm"

override fun getVersionRequirement(): RangesList = RangesListFactory.create("6.* - 8.*")
override fun getVersionRequirement(): RangesList = RangesListFactory.create("6.* - 10.*")

override fun mapDefinitionFiles(definitionFiles: List<File>) = mapDefinitionFilesForNpm(definitionFiles).toList()

Expand Down

0 comments on commit e2ed458

Please sign in to comment.