-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
45 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,47 @@ | ||
FROM nvcr.io/nvidia/pytorch:23.03-py3 | ||
# https://docs.nvidia.com/deeplearning/frameworks/pytorch-release-notes/rel_22-02.html#rel_22-02 | ||
# pytroch 2.0 cuda 12.1.0 ubuntu 20.04 | ||
RUN export DEBIAN_FRONTEND=noninteractive && export TZ=Etc/UTC && apt-get update \ | ||
&& apt install software-properties-common ca-certificates -y \ | ||
&& add-apt-repository ppa:flexiondotorg/nvtop \ | ||
&& apt install -y nvtop \ | ||
&& apt-get -y install git aria2 byobu \ | ||
&& git config --global http.sslverify "false" \ | ||
&& apt -y install build-essential \ | ||
&& apt-get install ffmpeg libsm6 libxext6 unzip -y \ | ||
&& pip install openmim \ | ||
&& apt install cmake libncurses5-dev libncursesw5-dev git -y | ||
# Install ubuntu packages | ||
RUN apt-get update && \ | ||
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \ | ||
build-essential \ | ||
git \ | ||
byobu \ | ||
zip \ | ||
wget \ | ||
curl \ | ||
ca-certificates \ | ||
locales \ | ||
openssh-server \ | ||
ffmpeg \ | ||
libsm6 \ | ||
libxext6 \ | ||
vim && \ | ||
rm -rf /var/lib/apt/lists/* && \ | ||
apt-get remove -y unattended-upgrades && \ | ||
# Set locale | ||
locale-gen en_US.UTF-8 && \ | ||
update-locale LANG=en_US.UTF-8 | ||
ENV LANG en_US.utf8 | ||
# Setup timezone | ||
# Start with a base Python image, lightweight version, compatible with ARM64 architectures | ||
FROM python:3.9-slim | ||
|
||
# Set noninteractive mode for apt-get to avoid prompts during build | ||
ENV DEBIAN_FRONTEND=noninteractive | ||
|
||
# Set your working timezone | ||
ENV TZ=Australia/Adelaide | ||
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone | ||
|
||
# Update and install basic utilities including byobu for terminal multiplexing | ||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
build-essential \ | ||
git \ | ||
byobu \ | ||
wget \ | ||
curl \ | ||
ca-certificates \ | ||
ffmpeg \ | ||
libsm6 \ | ||
libxext6 \ | ||
vim \ | ||
locales \ | ||
openssh-server \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# Set locale | ||
RUN locale-gen en_US.UTF-8 && \ | ||
update-locale LANG=en_US.UTF-8 | ||
ENV LANG en_US.utf8 | ||
|
||
# Additional dependencies or setup commands can go here | ||
# For example, to configure git to bypass SSL verification (not recommended for production) | ||
RUN git config --global http.sslverify "false" | ||
|
||
# Here you can add the requirements.txt file to your Docker image and install Python dependencies | ||
# COPY requirements.txt /app/ | ||
# RUN pip install --no-cache-dir -r /app/requirements.txt | ||
|
||
# Alternatively, directly install essential ML libraries as an example | ||
RUN pip install --no-cache-dir \ | ||
matplotlib \ | ||
scikit-learn \ | ||
pandas \ | ||
numpy \ | ||
-r requirements.txt | ||
# Your additional setup could go here |