diff --git a/.github/workflows/buildx.yml b/.github/workflows/buildx.yml index 9f764c2..101faa3 100644 --- a/.github/workflows/buildx.yml +++ b/.github/workflows/buildx.yml @@ -36,13 +36,23 @@ jobs: platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x,linux/386,linux/arm/v7,linux/arm/v6 - path: 3.3/18 - tags: "3.3 3.3-18 3.3-hydrogen" + tags: "3.3-18 3.3-hydrogen" platforms: linux/amd64,linux/arm64,linux/arm/v7 - path: 3.3/18/slim - tags: "3.3-slim 3.3-slim-18 3.3-slim-hydrogen" + tags: "3.3-slim-18 3.3-slim-hydrogen" platforms: linux/amd64,linux/arm64,linux/arm/v7 - path: 3.3/18/alpine - tags: "3.3-alpine 3.3-alpine-18 3.3-alpine-hydrogen" + tags: "3.3-alpine-18 3.3-alpine-hydrogen" + platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x,linux/386,linux/arm/v7,linux/arm/v6 + + - path: 3.4/18 + tags: "3.4-18 3.4-hydrogen" + platforms: linux/amd64,linux/arm64,linux/arm/v7 + - path: 3.4/18/slim + tags: "3.4-slim-18 3.4-slim-hydrogen" + platforms: linux/amd64,linux/arm64,linux/arm/v7 + - path: 3.4/18/alpine + tags: "3.4-alpine-18 3.4-alpine-hydrogen" platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x,linux/386,linux/arm/v7,linux/arm/v6 - path: 3.1/20 @@ -56,23 +66,33 @@ jobs: platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x,linux/386,linux/arm/v7,linux/arm/v6 - path: 3.2/20 - tags: "3.2 3.2-20 3.2-iron latest" + tags: "3.2 3.2-20 3.2-iron" platforms: linux/amd64,linux/arm64,linux/arm/v7 - path: 3.2/20/slim - tags: "3.2-slim 3.2-slim-20 3.2-slim-iron slim" + tags: "3.2-slim 3.2-slim-20 3.2-slim-iron" platforms: linux/amd64,linux/arm64,linux/arm/v7 - path: 3.2/20/alpine - tags: "3.2-alpine 3.2-alpine-20 3.2-alpine-iron alpine" + tags: "3.2-alpine 3.2-alpine-20 3.2-alpine-iron" platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x,linux/386,linux/arm/v7,linux/arm/v6 - path: 3.3/20 - tags: "3.3 3.3-20 3.3-iron" + tags: "3.3-20 3.3-iron 3.3 3 latest" platforms: linux/amd64,linux/arm64,linux/arm/v7 - path: 3.3/20/slim - tags: "3.3-slim 3.3-slim-20 3.3-slim-iron" + tags: " 3.3-slim-20 3.3-slim-iron 3.3-slim 3-slim slim" platforms: linux/amd64,linux/arm64,linux/arm/v7 - path: 3.3/20/alpine - tags: "3.3-alpine 3.3-alpine-20 3.3-alpine-iron" + tags: "3.3-alpine-20 3.3-alpine-iron 3.3-alpine 3-alpine alpine" + platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x,linux/386,linux/arm/v7,linux/arm/v6 + + - path: 3.4/20 + tags: "3.4-20 3.4-iron 3.4" + platforms: linux/amd64,linux/arm64,linux/arm/v7 + - path: 3.4/20/slim + tags: "3.4-slim-20 3.4-slim-iron 3.4-slim" + platforms: linux/amd64,linux/arm64,linux/arm/v7 + - path: 3.4/20/alpine + tags: "3.4-alpine-20 3.4-alpine-iron 3.4-alpine" platforms: linux/amd64,linux/arm64,linux/ppc64le,linux/s390x,linux/386,linux/arm/v7,linux/arm/v6 steps: - name: Checkout diff --git a/.github/workflows/dockerimage.yml b/.github/workflows/dockerimage.yml index 23cab35..c1e3ea5 100644 --- a/.github/workflows/dockerimage.yml +++ b/.github/workflows/dockerimage.yml @@ -36,6 +36,13 @@ jobs: echo "3.3 alpine with Node.js 18" docker run -i $(docker build -q 3.3/18/alpine) /bin/sh -c "ruby --version && node --version && npm --version" + echo "3.4 with Node.js 18" + docker run -i $(docker build -q 3.4/18) /bin/sh -c "ruby --version && node --version && npm --version" + echo "3.4 slim with Node.js 18" + docker run -i $(docker build -q 3.4/18/slim) /bin/sh -c "ruby --version && node --version && npm --version" + echo "3.4 alpine with Node.js 18" + docker run -i $(docker build -q 3.4/18/alpine) /bin/sh -c "ruby --version && node --version && npm --version" + echo "3.1 with Node.js 20" docker run -i $(docker build -q 3.1/20) /bin/sh -c "ruby --version && node --version && npm --version" echo "3.1 slim with Node.js 20" @@ -56,6 +63,13 @@ jobs: docker run -i $(docker build -q 3.3/20/slim) /bin/sh -c "ruby --version && node --version && npm --version" echo "3.3 alpine with Node.js 20" docker run -i $(docker build -q 3.3/20/alpine) /bin/sh -c "ruby --version && node --version && npm --version" + + echo "3.4 with Node.js 20" + docker run -i $(docker build -q 3.4/20) /bin/sh -c "ruby --version && node --version && npm --version" + echo "3.4 slim with Node.js 20" + docker run -i $(docker build -q 3.4/20/slim) /bin/sh -c "ruby --version && node --version && npm --version" + echo "3.4 alpine with Node.js 20" + docker run -i $(docker build -q 3.4/20/alpine) /bin/sh -c "ruby --version && node --version && npm --version" auto-merge: runs-on: ubuntu-latest needs: build diff --git a/.github/workflows/hadolint.yml b/.github/workflows/hadolint.yml index 67933c7..14d834d 100644 --- a/.github/workflows/hadolint.yml +++ b/.github/workflows/hadolint.yml @@ -15,5 +15,5 @@ jobs: - run: brew install hadolint - run: | - hadolint {3.1,3.2,3.3}/**/*Dockerfile - hadolint {3.1,3.2,3.3}/**/**/*Dockerfile + hadolint {3.1,3.2,3.3,3.4}/**/*Dockerfile + hadolint {3.1,3.2,3.3,3.4}/**/**/*Dockerfile diff --git a/3.4/18/Dockerfile b/3.4/18/Dockerfile new file mode 100644 index 0000000..228008f --- /dev/null +++ b/3.4/18/Dockerfile @@ -0,0 +1,19 @@ +FROM ruby:3.4-rc +LABEL maintainer "Tim Brust " + +ARG REFRESHED_AT +ENV REFRESHED_AT $REFRESHED_AT +ARG NODE_MAJOR=18 + +SHELL ["/bin/bash", "-o", "pipefail", "-c"] + +RUN printf 'Package: nodejs\nPin: origin deb.nodesource.com\nPin-Priority: 1001' > /etc/apt/preferences.d/nodesource \ + && mkdir -p /etc/apt/keyrings \ + && 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_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \ + && apt-get update -qq && apt-get install -qq --no-install-recommends \ + nodejs \ + && apt-get upgrade -qq \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/*\ + && npm install -g yarn@1 diff --git a/3.4/18/alpine/Dockerfile b/3.4/18/alpine/Dockerfile new file mode 100644 index 0000000..47c8b8f --- /dev/null +++ b/3.4/18/alpine/Dockerfile @@ -0,0 +1,11 @@ +FROM ruby:3.4-rc-alpine +LABEL maintainer "Tim Brust " + +ARG REFRESHED_AT +ENV REFRESHED_AT $REFRESHED_AT + +RUN apk -U upgrade \ + && apk add --no-cache \ + nodejs \ + npm \ + yarn diff --git a/3.4/18/slim/Dockerfile b/3.4/18/slim/Dockerfile new file mode 100644 index 0000000..790ea3d --- /dev/null +++ b/3.4/18/slim/Dockerfile @@ -0,0 +1,25 @@ +FROM ruby:3.4-rc-slim +LABEL maintainer "Tim Brust " + +ARG REFRESHED_AT +ENV REFRESHED_AT $REFRESHED_AT +ARG NODE_MAJOR=18 + +# hadolint ignore=DL3009 +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + curl \ + gnupg2 \ + libatomic1 + +SHELL ["/bin/bash", "-o", "pipefail", "-c"] + +RUN printf 'Package: nodejs\nPin: origin deb.nodesource.com\nPin-Priority: 1001' > /etc/apt/preferences.d/nodesource \ + && mkdir -p /etc/apt/keyrings \ + && 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_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \ + && apt-get update -qq && apt-get install -qq --no-install-recommends \ + nodejs \ + && apt-get upgrade -qq \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/*\ + && npm install -g yarn@1 diff --git a/3.4/20/Dockerfile b/3.4/20/Dockerfile new file mode 100644 index 0000000..52174d5 --- /dev/null +++ b/3.4/20/Dockerfile @@ -0,0 +1,19 @@ +FROM ruby:3.4 +LABEL maintainer "Tim Brust " + +ARG REFRESHED_AT +ENV REFRESHED_AT $REFRESHED_AT +ARG NODE_MAJOR=20 + +SHELL ["/bin/bash", "-o", "pipefail", "-c"] + +RUN printf 'Package: nodejs\nPin: origin deb.nodesource.com\nPin-Priority: 1001' > /etc/apt/preferences.d/nodesource \ + && mkdir -p /etc/apt/keyrings \ + && 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_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \ + && apt-get update -qq && apt-get install -qq --no-install-recommends \ + nodejs \ + && apt-get upgrade -qq \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/*\ + && npm install -g yarn@1 diff --git a/3.4/20/alpine/Dockerfile b/3.4/20/alpine/Dockerfile new file mode 100644 index 0000000..9784ea1 --- /dev/null +++ b/3.4/20/alpine/Dockerfile @@ -0,0 +1,13 @@ +FROM ruby:3.4-rc-alpine +LABEL maintainer "Tim Brust " + +ARG REFRESHED_AT +ENV REFRESHED_AT $REFRESHED_AT + +RUN echo @edge https://dl-cdn.alpinelinux.org/alpine/edge/community >> /etc/apk/repositories \ + && echo @edge https://dl-cdn.alpinelinux.org/alpine/edge/main >> /etc/apk/repositories \ + && apk -U upgrade \ + && apk add --no-cache \ + nodejs@edge \ + npm@edge \ + yarn diff --git a/3.4/20/slim/Dockerfile b/3.4/20/slim/Dockerfile new file mode 100644 index 0000000..c092b8d --- /dev/null +++ b/3.4/20/slim/Dockerfile @@ -0,0 +1,25 @@ +FROM ruby:3.4-rc-slim +LABEL maintainer "Tim Brust " + +ARG REFRESHED_AT +ENV REFRESHED_AT $REFRESHED_AT +ARG NODE_MAJOR=20 + +# hadolint ignore=DL3009 +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + curl \ + gnupg2 \ + libatomic1 + +SHELL ["/bin/bash", "-o", "pipefail", "-c"] + +RUN printf 'Package: nodejs\nPin: origin deb.nodesource.com\nPin-Priority: 1001' > /etc/apt/preferences.d/nodesource \ + && mkdir -p /etc/apt/keyrings \ + && 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_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \ + && apt-get update -qq && apt-get install -qq --no-install-recommends \ + nodejs \ + && apt-get upgrade -qq \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/*\ + && npm install -g yarn@1 diff --git a/README.md b/README.md index 95ec232..a570f4d 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,14 @@ -# Ruby 3.1, 3.2 or 3.3 with Node.js 18 LTS or Node.js 20 LTS Dockerfile +# Ruby 3.1, 3.2, 3.3 or 3.4 (RC) with Node.js 18 LTS or Node.js 20 LTS Dockerfile [![Docker Automated build](https://img.shields.io/docker/automated/timbru31/ruby-node.svg)](https://hub.docker.com/r/timbru31/ruby-node/) [![buildx Status](https://github.com/timbru31/docker-ruby-node/workflows/buildx/badge.svg)](https://github.com/timbru31/docker-ruby-node/actions?query=workflow%3Abuildx) [![Lint Dockerfiles](https://github.com/timbru31/docker-ruby-node/workflows/Lint%20Dockerfiles/badge.svg)](https://github.com/timbru31/docker-ruby-node/actions?query=workflow%3A%22Lint+Dockerfiles%22) -A minimal Dockerfile based on Ruby (3.1, 3.2 or 3.3) Dockerfile (regular, slim or alpine) with Node.js 18 LTS (Hydrogen) or Node.js 20 LTS (Iron) installed. +A minimal Dockerfile based on Ruby (3.1, 3.2, 3.3 or 3.4 (RC)) Dockerfile (regular, slim or alpine) with Node.js 18 LTS (Hydrogen) or Node.js 20 LTS (Iron) installed. ## What's included -- Ruby 3.1, 3.2, 3.3 +- Ruby 3.1, 3.2, 3.3, 3.4 (RC) - Node.js 18 LTS (Hydrogen) or Node.js 20 LTS (Iron) - bundled npm that comes with the respective Node.js version (latest for Node.js LTS on alpine, see [why](https://gitlab.alpinelinux.org/alpine/aports/-/commit/25b10bd1a93e12a7e49fee38b0a229281ae49fb7)) - yarn