forked from timbru31/docker-java-node
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
27 lines (24 loc) · 1.07 KB
/
Dockerfile
File metadata and controls
27 lines (24 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
FROM eclipse-temurin:25-jdk
LABEL maintainer="Tim Brust <github@timbrust.de>"
ARG REFRESHED_AT
ENV REFRESHED_AT=$REFRESHED_AT
ARG NODE_MAJOR=24
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 \
&& apt-get update -qq \
&& apt-get install -qq --no-install-recommends \
gpg \
gpg-agent \
curl \
&& 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 \
&& curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \
&& echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list \
&& apt-get update -qq \
&& apt-get install -qq --no-install-recommends \
nodejs \
yarn \
git \
&& apt-get upgrade -qq \
&& rm -rf /var/lib/apt/lists/*