Update Docker COPY permissions (#13200)
Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This commit is contained in:
parent
a07d6492eb
commit
d80bd840d1
5 changed files with 43 additions and 33 deletions
|
|
@ -6,6 +6,9 @@
|
|||
# Start FROM Debian image for arm64v8 https://hub.docker.com/r/arm64v8/debian (new)
|
||||
FROM arm64v8/debian:bookworm-slim
|
||||
|
||||
# Set environment variables
|
||||
ENV APP_HOME /usr/src/ultralytics
|
||||
|
||||
# Downloads to user config dir
|
||||
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
||||
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
||||
|
|
@ -19,12 +22,12 @@ RUN apt update \
|
|||
&& apt install --no-install-recommends -y python3-pip git zip curl htop gcc libgl1 libglib2.0-0 libpython3-dev gnupg g++ libusb-1.0-0 build-essential
|
||||
|
||||
# Create working directory
|
||||
WORKDIR /usr/src/ultralytics
|
||||
WORKDIR $APP_HOME
|
||||
|
||||
# Copy contents
|
||||
# COPY . /usr/src/ultralytics # git permission issues inside container
|
||||
RUN git clone https://github.com/ultralytics/ultralytics -b main /usr/src/ultralytics
|
||||
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt /usr/src/ultralytics/
|
||||
# Copy contents and assign permissions
|
||||
COPY . $APP_HOME
|
||||
RUN chown -R root:root $APP_HOME
|
||||
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt $APP_HOME
|
||||
|
||||
# Remove python3.11/EXTERNALLY-MANAGED to avoid 'externally-managed-environment' issue, Debian 12 Bookworm error
|
||||
RUN rm -rf /usr/lib/python3.11/EXTERNALLY-MANAGED
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue