Skip to content

Commit e8964dc

Browse files
committed
Updated dockerfiles.
1 parent 8894cf1 commit e8964dc

File tree

2 files changed

+98
-78
lines changed

2 files changed

+98
-78
lines changed

Dockerfile_singleuser

Lines changed: 55 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -30,49 +30,15 @@ RUN apt-add-repository multiverse && \
3030
apt-add-repository universe && \
3131
add-apt-repository ppa:graphics-drivers/ppa && \
3232
add-apt-repository ppa:deadsnakes/ppa && \
33-
apt-get update && apt-get upgrade -y
34-
35-
# run updates
36-
RUN apt-get update && apt-get upgrade -y && dpkg --configure -a && \
37-
apt-get --force-yes -o Dpkg::Options::="--force-confold" --force-yes -o Dpkg::Options::="--force-confdef" -fuy full-upgrade && \
38-
apt-get autoremove -y && \
39-
apt-get clean -y && \
40-
apt-get install -y \
41-
gnupg \
42-
ssl-cert \
43-
libevent-dev \
44-
libsqlite3-dev \
45-
libxml2-dev \
46-
libbz2-dev \
47-
libxslt1-dev \
48-
zlib1g-dev \
49-
libssl-dev \
50-
wget \
51-
curl \
52-
gnupg-agent \
53-
dirmngr \
54-
ca-certificates \
55-
apt-transport-https \
56-
apt-utils \
57-
fonts-dejavu \
58-
nano \
59-
iputils-ping \
60-
cmake \
61-
make \
62-
build-essential \
63-
unixodbc \
64-
unixodbc-dev \
65-
r-cran-rodbc \
66-
gfortran \
67-
gcc \
68-
g++ \
69-
git \
70-
ssh \
71-
jq \
72-
htop \
73-
libgl1-mesa-glx libegl1-mesa libxrandr2 libxrandr2 libxss1 \
74-
libxcursor1 libxcomposite1 libasound2 libxi6 libxtst6 \
75-
r-base
33+
apt-get update && apt-get upgrade -y && \
34+
apt-get --force-yes -o Dpkg::Options::="--force-confold" --force-yes -o Dpkg::Options::="--force-confdef" -fuy full-upgrade && \
35+
apt-get autoremove -y && \
36+
apt-get clean -y && \
37+
apt-get install -y \
38+
wget \
39+
curl \
40+
ca-certificates \
41+
apt-transport-https
7642

7743
# Microsoft repos
7844
RUN wget -q -O- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor -o /etc/apt/trusted.gpg.d/packages.microsoft.gpg
@@ -105,6 +71,52 @@ RUN if [ "${CPU_ARCHITECTURE}" = "amd64" ]; then \
10571
echo "No valid CPU_ARCHITECTURE specified"; \
10672
fi
10773

74+
# python 3.11 repo
75+
RUN apt-get update -y && apt-get upgrade -y
76+
77+
# run updates
78+
RUN apt-get update && apt-get upgrade -y && dpkg --configure -a && \
79+
apt-get --force-yes -o Dpkg::Options::="--force-confold" --force-yes -o Dpkg::Options::="--force-confdef" -fuy full-upgrade && \
80+
apt-get autoremove -y && \
81+
apt-get clean -y && \
82+
apt-get install -y \
83+
gnupg \
84+
ssl-cert \
85+
libevent-dev \
86+
libsqlite3-dev \
87+
libxml2-dev \
88+
libbz2-dev \
89+
libxslt1-dev \
90+
zlib1g-dev \
91+
libssl-dev \
92+
wget \
93+
curl \
94+
gnupg-agent \
95+
dirmngr \
96+
ca-certificates \
97+
apt-transport-https \
98+
apt-utils \
99+
fonts-dejavu \
100+
nano \
101+
iputils-ping \
102+
cmake \
103+
make \
104+
build-essential \
105+
unixodbc \
106+
unixodbc-dev \
107+
r-cran-rodbc \
108+
gfortran \
109+
gcc \
110+
g++ \
111+
git \
112+
ssh \
113+
jq \
114+
htop \
115+
libgl1-mesa-glx libegl1-mesa libxrandr2 libxrandr2 libxss1 \
116+
libxcursor1 libxcomposite1 libasound2 libxi6 libxtst6 \
117+
r-base
118+
119+
108120
# remove newer python version, freeze other versions for max compatibility before updates
109121
RUN apt --fix-missing purge $(dpkg -l | grep 'python3\.1[01]' | awk '{print $2}')
110122
RUN apt --fix-broken install

Dockerfile_singleuser_gpu

Lines changed: 43 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,49 @@ RUN apt-add-repository multiverse && \
3636
apt-add-repository universe && \
3737
add-apt-repository ppa:graphics-drivers/ppa && \
3838
add-apt-repository ppa:deadsnakes/ppa && \
39-
apt-get update && apt-get upgrade -y
39+
apt-get update && apt-get upgrade -y && \
40+
apt-get --force-yes -o Dpkg::Options::="--force-confold" --force-yes -o Dpkg::Options::="--force-confdef" -fuy full-upgrade && \
41+
apt-get autoremove -y && \
42+
apt-get clean -y && \
43+
apt-get install -y \
44+
wget \
45+
curl \
46+
ca-certificates \
47+
apt-transport-https
48+
49+
# Microsoft repos
50+
RUN wget -q -O- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor -o /etc/apt/trusted.gpg.d/packages.microsoft.gpg
51+
RUN curl https://packages.microsoft.com/config/ubuntu/22.04/prod.list >> /etc/apt/sources.list.d/mssql-release.list
52+
RUN echo "deb [arch=arm64] https://packages.microsoft.com/ubuntu/22.04/prod jammy main" | tee -a /etc/apt/sources.list
53+
54+
# Add latest ubuntu repos to sources.list
55+
# add arch
56+
RUN if [ "${CPU_ARCHITECTURE}" = "amd64" ]; then \
57+
echo "deb http://archive.ubuntu.com/ubuntu/ jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
58+
echo "deb-src http://archive.ubuntu.com/ubuntu/ jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
59+
echo "deb http://archive.ubuntu.com/ubuntu/ jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
60+
echo "deb-src http://archive.ubuntu.com/ubuntu/ jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
61+
echo "deb http://archive.ubuntu.com/ubuntu/ jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
62+
echo "deb-src http://archive.ubuntu.com/ubuntu/ jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
63+
echo "deb http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
64+
echo "deb-src http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
65+
elif [ "${CPU_ARCHITECTURE}" = "arm64" ]; then \
66+
echo "deb [arch=arm64] http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
67+
echo "deb-src [arch=arm64] http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
68+
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
69+
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-updates main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
70+
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
71+
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
72+
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
73+
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-updates main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
74+
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
75+
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
76+
else \
77+
echo "No valid CPU_ARCHITECTURE specified"; \
78+
fi
79+
80+
# python 3.11 repo
81+
RUN apt-get update -y && apt-get upgrade -y
4082

4183
# run updates
4284
RUN apt-get update && apt-get upgrade -y && dpkg --configure -a && \
@@ -53,12 +95,8 @@ RUN apt-get update && apt-get upgrade -y && dpkg --configure -a && \
5395
libxslt1-dev \
5496
zlib1g-dev \
5597
libssl-dev \
56-
wget \
57-
curl \
5898
gnupg-agent \
5999
dirmngr \
60-
ca-certificates \
61-
apt-transport-https \
62100
apt-utils \
63101
fonts-dejavu \
64102
nano \
@@ -80,36 +118,6 @@ RUN apt-get update && apt-get upgrade -y && dpkg --configure -a && \
80118
libxcursor1 libxcomposite1 libasound2 libxi6 libxtst6 \
81119
r-base
82120

83-
# Microsoft repos
84-
RUN wget -q -O- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor -o /etc/apt/trusted.gpg.d/packages.microsoft.gpg
85-
RUN curl https://packages.microsoft.com/config/ubuntu/22.04/prod.list >> /etc/apt/sources.list.d/mssql-release.list
86-
RUN echo "deb [arch=arm64] https://packages.microsoft.com/ubuntu/22.04/prod jammy main" | tee -a /etc/apt/sources.list
87-
88-
# Add latest ubuntu repos to sources.list
89-
# add arch
90-
RUN if [ "${CPU_ARCHITECTURE}" = "amd64" ]; then \
91-
echo "deb http://archive.ubuntu.com/ubuntu/ jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
92-
echo "deb-src http://archive.ubuntu.com/ubuntu/ jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
93-
echo "deb http://archive.ubuntu.com/ubuntu/ jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
94-
echo "deb-src http://archive.ubuntu.com/ubuntu/ jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
95-
echo "deb http://archive.ubuntu.com/ubuntu/ jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
96-
echo "deb-src http://archive.ubuntu.com/ubuntu/ jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
97-
echo "deb http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
98-
echo "deb-src http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
99-
elif [ "${CPU_ARCHITECTURE}" = "arm64" ]; then \
100-
echo "deb [arch=arm64] http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
101-
echo "deb-src [arch=arm64] http://archive.canonical.com/ubuntu/ jammy partner" | tee -a /etc/apt/sources.list ; \
102-
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
103-
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-updates main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
104-
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
105-
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
106-
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-security main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
107-
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-updates main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
108-
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-backports main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
109-
echo "deb-src [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy main restricted universe multiverse" | tee -a /etc/apt/sources.list ; \
110-
else \
111-
echo "No valid CPU_ARCHITECTURE specified"; \
112-
fi
113121

114122
# remove newer python version, freeze other versions for max compatibility before updates
115123
RUN apt --fix-missing purge $(dpkg -l | grep 'python3\.1[01]' | awk '{print $2}')

0 commit comments

Comments
 (0)