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
|
|
@ -5,6 +5,9 @@
|
|||
# Start FROM https://catalog.ngc.nvidia.com/orgs/nvidia/containers/l4t-pytorch
|
||||
FROM nvcr.io/nvidia/l4t-pytorch:r35.2.1-pth2.0-py3
|
||||
|
||||
# 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 \
|
||||
|
|
@ -18,12 +21,12 @@ RUN apt update \
|
|||
&& apt install --no-install-recommends -y gcc git zip curl htop libgl1 libglib2.0-0 libpython3-dev gnupg g++ libusb-1.0-0
|
||||
|
||||
# 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 opencv-python from Ultralytics dependencies as it conflicts with opencv-python installed in base image
|
||||
RUN grep -v "opencv-python" pyproject.toml > temp.toml && mv temp.toml pyproject.toml
|
||||
|
|
@ -37,9 +40,6 @@ RUN pip install onnxruntime_gpu-1.15.1-cp38-cp38-linux_aarch64.whl
|
|||
RUN pip install --no-cache-dir tqdm matplotlib pyyaml psutil pandas onnx
|
||||
RUN pip install --no-cache-dir -e ".[export]"
|
||||
|
||||
# Set environment variables
|
||||
ENV OMP_NUM_THREADS=1
|
||||
|
||||
|
||||
# Usage Examples -------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue