Skip to content

Commit 2af4514

Browse files
committed
chore(linter): fix hadolint warnings
1 parent 6037419 commit 2af4514

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

templates/alpine.Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ FROM python:{{ python_image }} AS builder
66
# Install node prereqs, nodejs and yarn
77
# Ref: https://raw.githubusercontent.com/nodejs/docker-node/master/Dockerfile-alpine.template
88
# Ref: https://yarnpkg.com/en/docs/install
9-
RUN apk add curl
9+
RUN apk add --no-cache curl && rm /var/cache/apk/*
1010
# FIXME: no arm + musl build yet
1111
# Ref: https://github.com/nodejs/unofficial-builds/pull/59
1212
# Ref: https://github.com/nodejs/node/pull/45756
@@ -19,10 +19,10 @@ FROM python:{{ python_image }}
1919
LABEL org.opencontainers.image.authors="Nikolai R Kristiansen <nikolaik@gmail.com>"
2020

2121
RUN addgroup -g 1000 pn && adduser -u 1000 -G pn -s /bin/sh -D pn
22-
RUN apk add libstdc++
22+
RUN apk add --no-cache libstdc++ && rm /var/cache/apk/*
2323
COPY --from=builder /node-v{{ nodejs_canonical }}-linux-x64-musl /usr/local
2424
RUN corepack enable yarn
25-
RUN pip install -U pip pipenv uv
25+
RUN pip install --no-cache-dir -U pip pipenv uv
2626

2727
# Poetry
2828
# Mimic what https://install.python-poetry.org does without the flexibility (platforms, install sources, etc).

templates/debian.Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ RUN groupadd --gid 1000 pn && useradd --uid 1000 --gid pn --shell /bin/bash --cr
88
ENV POETRY_HOME=/usr/local
99

1010
RUN \
11-
{% if distro_variant == "slim" %} apt-get update && apt-get install curl gnupg2 xz-utils -yqq && \
11+
{% if distro_variant == "slim" %} apt-get update && apt-get install --no-install-recommends curl gnupg2 xz-utils -yqq && \
1212
{% endif %} apt-get upgrade -yqq && \
1313
rm -rf /var/lib/apt/lists/*
1414
RUN NODE_VERSION="v{{ nodejs_canonical }}" \
@@ -31,5 +31,5 @@ RUN NODE_VERSION="v{{ nodejs_canonical }}" \
3131
&& ln -s /usr/local/bin/node /usr/local/bin/nodejs
3232
RUN corepack enable yarn
3333

34-
RUN pip install -U pip pipenv uv && \
34+
RUN pip install --no-cache-dir -U pip pipenv uv && \
3535
curl -fsSL --compressed https://install.python-poetry.org | python -

0 commit comments

Comments
 (0)