-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
149 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: Build Node 20 base on JDK 21 | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
paths: | ||
# '*' matches any character except '/' | ||
- '20-jdk21/*' | ||
- '.github/workflows/build-node20-jdk21.yml' | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@master | ||
- name: Docker login | ||
env: | ||
DOCKER_HUB_USERNAME: ${{ secrets. DOCKER_HUB_USERNAME }} | ||
DOCKER_HUB_PASSWORD: ${{ secrets. DOCKER_HUB_PASSWORD }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
run: | | ||
echo $DOCKER_HUB_PASSWORD | docker login --username $DOCKER_HUB_USERNAME --password-stdin | ||
echo $GITHUB_TOKEN | docker login docker.pkg.github.com --username $GITHUB_ACTOR --password-stdin | ||
|
||
- name: Build & Push Docker Image | ||
run: | | ||
cd 20-jdk21 | ||
IMAGE_NAME=ringcentral/node | ||
GH_DOCKER_PKG_IMAGE_NAME=docker.pkg.github.com/ringcentral-docker/node/node | ||
|
||
NODE_VERSION="$(awk '/ENV NODE_VERSION/ {print $3}' Dockerfile)" | ||
BASE_VERSION="$(awk -F '[:-]' '/FROM/ {print $3}' Dockerfile)" | ||
|
||
docker build --tag ${IMAGE_NAME} --file Dockerfile . | ||
|
||
docker tag "${IMAGE_NAME}" "${IMAGE_NAME}:${NODE_VERSION}-${BASE_VERSION}" | ||
|
||
docker push "${IMAGE_NAME}:${NODE_VERSION}-${BASE_VERSION}" | ||
|
||
docker tag "${IMAGE_NAME}" "${GH_DOCKER_PKG_IMAGE_NAME}:${NODE_VERSION}-${BASE_VERSION}" | ||
|
||
docker push "${GH_DOCKER_PKG_IMAGE_NAME}:${NODE_VERSION}-${BASE_VERSION}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
FROM ringcentral/maven:3.8.8-jdk11.0.22 | ||
LABEL maintainer="[email protected]" | ||
|
||
ENV NODE_VERSION 16.20.2 | ||
ENV NODE_VERSION 20.12.1 | ||
|
||
#=============== | ||
# Build nodejs | ||
|
@@ -11,7 +11,7 @@ RUN apk add --no-cache \ | |
git \ | ||
bzip2 \ | ||
unzip \ | ||
&& apk add --no-cache --virtual .build-deps \ | ||
&& apk add --no-cache --virtual .build-deps-full \ | ||
binutils-gold \ | ||
curl \ | ||
g++ \ | ||
|
@@ -21,35 +21,43 @@ RUN apk add --no-cache \ | |
linux-headers \ | ||
make \ | ||
python3 \ | ||
# use pre-existing gpg directory, see https://github.com/nodejs/docker-node/pull/1895#issuecomment-1550389150 | ||
&& export GNUPGHOME="$(mktemp -d)" \ | ||
# gpg keys listed at https://github.com/nodejs/node#release-keys | ||
&& for key in \ | ||
4ED778F539E3634C779C87C6D7062848A1AB005C \ | ||
141F07595B7B3FFE74309A937405533BE57C7D57 \ | ||
74F12602B6F1C4E913FAA37AD3A89613643B6201 \ | ||
DD792F5973C6DE52C432CBDAC77ABFA00DDBF2B7 \ | ||
61FC681DFB92A079F1685E77973F295594EC4689 \ | ||
8FCCA13FEF1D0C2E91008E09770F7A9A5AE15600 \ | ||
C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ | ||
890C08DB8579162FEE0DF9DB8BEAB4DFCF555EF4 \ | ||
C82FA3AE1CBEDC6BE46B9360C43CEC45C17AB93C \ | ||
108F52B48DB57BB0CC439B2997B01419BD92F80A \ | ||
A363A499291CBBC940DD62E41F10027AF002F8B0 \ | ||
CC68F5A3106FF448322E48ED27F5E38D5B0A215F \ | ||
; do \ | ||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys "$key" || \ | ||
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$key" ; \ | ||
done \ | ||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ | ||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ | ||
&& gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ | ||
&& gpgconf --kill all \ | ||
&& rm -rf "$GNUPGHOME" \ | ||
&& grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ | ||
&& tar -xf "node-v$NODE_VERSION.tar.xz" \ | ||
&& cd "node-v$NODE_VERSION" \ | ||
&& ./configure \ | ||
&& make -j$(getconf _NPROCESSORS_ONLN) V= \ | ||
&& make install \ | ||
&& apk del .build-deps \ | ||
&& apk del .build-deps-full \ | ||
&& cd .. \ | ||
&& rm -Rf "node-v$NODE_VERSION" \ | ||
&& rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt | ||
|
||
&& rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt; \ | ||
# Remove unused OpenSSL headers to save ~34MB. See this NodeJS issue: https://github.com/nodejs/node/issues/46451 | ||
&& find /usr/local/include/node/openssl/archs -mindepth 1 -maxdepth 1 ! -name "$OPENSSL_ARCH" -exec rm -rf {} \; | ||
|
||
#=============== | ||
# install yarn | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
FROM ringcentral/maven:3.8.8-jdk17.0.10 | ||
LABEL maintainer="[email protected]" | ||
|
||
ENV NODE_VERSION 16.20.2 | ||
ENV NODE_VERSION 20.12.1 | ||
|
||
#=============== | ||
# Build nodejs | ||
|
@@ -11,7 +11,7 @@ RUN apk add --no-cache \ | |
git \ | ||
bzip2 \ | ||
unzip \ | ||
&& apk add --no-cache --virtual .build-deps \ | ||
&& apk add --no-cache --virtual .build-deps-full \ | ||
binutils-gold \ | ||
curl \ | ||
g++ \ | ||
|
@@ -21,35 +21,43 @@ RUN apk add --no-cache \ | |
linux-headers \ | ||
make \ | ||
python3 \ | ||
# use pre-existing gpg directory, see https://github.com/nodejs/docker-node/pull/1895#issuecomment-1550389150 | ||
&& export GNUPGHOME="$(mktemp -d)" \ | ||
# gpg keys listed at https://github.com/nodejs/node#release-keys | ||
&& for key in \ | ||
4ED778F539E3634C779C87C6D7062848A1AB005C \ | ||
141F07595B7B3FFE74309A937405533BE57C7D57 \ | ||
74F12602B6F1C4E913FAA37AD3A89613643B6201 \ | ||
DD792F5973C6DE52C432CBDAC77ABFA00DDBF2B7 \ | ||
61FC681DFB92A079F1685E77973F295594EC4689 \ | ||
8FCCA13FEF1D0C2E91008E09770F7A9A5AE15600 \ | ||
C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ | ||
890C08DB8579162FEE0DF9DB8BEAB4DFCF555EF4 \ | ||
C82FA3AE1CBEDC6BE46B9360C43CEC45C17AB93C \ | ||
108F52B48DB57BB0CC439B2997B01419BD92F80A \ | ||
A363A499291CBBC940DD62E41F10027AF002F8B0 \ | ||
CC68F5A3106FF448322E48ED27F5E38D5B0A215F \ | ||
; do \ | ||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys "$key" || \ | ||
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$key" ; \ | ||
done \ | ||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ | ||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ | ||
&& gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ | ||
&& gpgconf --kill all \ | ||
&& rm -rf "$GNUPGHOME" \ | ||
&& grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ | ||
&& tar -xf "node-v$NODE_VERSION.tar.xz" \ | ||
&& cd "node-v$NODE_VERSION" \ | ||
&& ./configure \ | ||
&& make -j$(getconf _NPROCESSORS_ONLN) V= \ | ||
&& make install \ | ||
&& apk del .build-deps \ | ||
&& apk del .build-deps-full \ | ||
&& cd .. \ | ||
&& rm -Rf "node-v$NODE_VERSION" \ | ||
&& rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt | ||
|
||
&& rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt; \ | ||
# Remove unused OpenSSL headers to save ~34MB. See this NodeJS issue: https://github.com/nodejs/node/issues/46451 | ||
&& find /usr/local/include/node/openssl/archs -mindepth 1 -maxdepth 1 ! -name "$OPENSSL_ARCH" -exec rm -rf {} \; | ||
|
||
#=============== | ||
# install yarn | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
FROM ringcentral/maven:3.8.8-jdk21.0.2 | ||
LABEL maintainer="[email protected]" | ||
|
||
ENV NODE_VERSION 20.12.1 | ||
|
||
#=============== | ||
# Build nodejs | ||
#=============== | ||
RUN apk add --no-cache \ | ||
libstdc++ \ | ||
git \ | ||
bzip2 \ | ||
unzip \ | ||
&& apk add --no-cache --virtual .build-deps-full \ | ||
binutils-gold \ | ||
curl \ | ||
g++ \ | ||
gcc \ | ||
gnupg \ | ||
libgcc \ | ||
linux-headers \ | ||
make \ | ||
python3 \ | ||
# use pre-existing gpg directory, see https://github.com/nodejs/docker-node/pull/1895#issuecomment-1550389150 | ||
&& export GNUPGHOME="$(mktemp -d)" \ | ||
# gpg keys listed at https://github.com/nodejs/node#release-keys | ||
&& for key in \ | ||
4ED778F539E3634C779C87C6D7062848A1AB005C \ | ||
141F07595B7B3FFE74309A937405533BE57C7D57 \ | ||
74F12602B6F1C4E913FAA37AD3A89613643B6201 \ | ||
DD792F5973C6DE52C432CBDAC77ABFA00DDBF2B7 \ | ||
61FC681DFB92A079F1685E77973F295594EC4689 \ | ||
8FCCA13FEF1D0C2E91008E09770F7A9A5AE15600 \ | ||
C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \ | ||
890C08DB8579162FEE0DF9DB8BEAB4DFCF555EF4 \ | ||
C82FA3AE1CBEDC6BE46B9360C43CEC45C17AB93C \ | ||
108F52B48DB57BB0CC439B2997B01419BD92F80A \ | ||
A363A499291CBBC940DD62E41F10027AF002F8B0 \ | ||
CC68F5A3106FF448322E48ED27F5E38D5B0A215F \ | ||
; do \ | ||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys "$key" || \ | ||
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$key" ; \ | ||
done \ | ||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \ | ||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \ | ||
&& gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \ | ||
&& gpgconf --kill all \ | ||
&& rm -rf "$GNUPGHOME" \ | ||
&& grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \ | ||
&& tar -xf "node-v$NODE_VERSION.tar.xz" \ | ||
&& cd "node-v$NODE_VERSION" \ | ||
&& ./configure \ | ||
&& make -j$(getconf _NPROCESSORS_ONLN) V= \ | ||
&& make install \ | ||
&& apk del .build-deps-full \ | ||
&& cd .. \ | ||
&& rm -Rf "node-v$NODE_VERSION" \ | ||
&& rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt; \ | ||
# Remove unused OpenSSL headers to save ~34MB. See this NodeJS issue: https://github.com/nodejs/node/issues/46451 | ||
&& find /usr/local/include/node/openssl/archs -mindepth 1 -maxdepth 1 ! -name "$OPENSSL_ARCH" -exec rm -rf {} \; | ||
|
||
#=============== | ||
# install yarn | ||
#=============== | ||
RUN apk add --no-cache yarn | ||
|
||
#=============== | ||
# Show version | ||
#=============== | ||
RUN node --version | ||
RUN npm version | ||
RUN yarn --version |