Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(backport): Apply Docker build check corrections #2544

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
ARG BASE_IMAGE=python:3.12-slim-bullseye
# hadolint ignore=DL3006
FROM ${BASE_IMAGE} as base
FROM ${BASE_IMAGE} AS base

FROM base as builder
FROM base AS builder
# Set PATH to pickup virtual environment by default
ENV PATH=/usr/local/venv/bin:"${PATH}"
COPY . /code
Expand Down Expand Up @@ -49,10 +49,11 @@ RUN adduser \

COPY --from=builder --chown=moby /usr/local/venv /usr/local/venv/

# Does NOT define USER as ENV
USER moby

ENV USER ${USER}
ENV HOME /home/moby
ENV USER=moby
ENV HOME=/home/moby
WORKDIR ${HOME}/work

# Use C.UTF-8 locale to avoid issues with ASCII encoding
Expand Down
4 changes: 2 additions & 2 deletions docker/gpu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM nvidia/cuda:10.1-cudnn7-runtime-ubuntu18.04 as base
FROM nvidia/cuda:10.1-cudnn7-runtime-ubuntu18.04 AS base

FROM base as builder
FROM base AS builder
# hadolint ignore=DL3015
RUN apt-get update -y && \
apt-get install -y \
Expand Down
Loading