Pin Docker-cpu `FROM ubuntu:20.04` (#7677)

This commit is contained in:
Glenn Jocher 2022-05-02 23:27:24 -07:00 committed by GitHub
parent c4862fcd31
commit e305aba686
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 9 deletions

View File

@ -1,22 +1,18 @@
# YOLOv5 🚀 by Ultralytics, GPL-3.0 license
# Start FROM Ubuntu image https://hub.docker.com/_/ubuntu
FROM ubuntu:latest
FROM ubuntu:20.04
# Install linux packages
RUN apt update
RUN DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt install -y tzdata
RUN apt install -y python3-pip git zip curl htop screen libgl1-mesa-glx libglib2.0-0 software-properties-common
# Install python3.9
RUN add-apt-repository ppa:deadsnakes/ppa -y
RUN apt install python3.9 python3.9-distutils libpython3.9 -y
# RUN alias python=python3.9
RUN apt install -y python3-pip git zip curl htop screen libgl1-mesa-glx libglib2.0-0
# RUN alias python=python3
# Install pip packages
COPY requirements.txt .
RUN python3.9 -m pip install --upgrade pip
RUN python3.9 -m pip install --no-cache -r requirements.txt albumentations gsutil notebook \
RUN python3 -m pip install --upgrade pip
RUN pip install --no-cache -r requirements.txt albumentations gsutil notebook \
coremltools onnx onnx-simplifier onnxruntime openvino-dev tensorflow-cpu tensorflowjs \
torch torchvision --extra-index-url https://download.pytorch.org/whl/cpu