Skip to content

Commit ce01d56

Browse files
committed
Add rust compiler to linux docker images
1 parent 0525eae commit ce01d56

File tree

3 files changed

+20
-0
lines changed

3 files changed

+20
-0
lines changed

docker/debian/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ RUN <<EOF
4040
pkgs=()
4141
pkgs+=(ca-certificates) # Enable TLS verification for HTTPS connections by providing trusted root certificates.
4242
pkgs+=(binutils-gold) # Required build tool.
43+
pkgs+=(cargo) # Package manager for Rust applications.
4344
pkgs+=(curl) # Dependency for tools requiring downloading data.
4445
pkgs+=(dpkg-dev) # Required packaging tool.
4546
pkgs+=(debhelper) # Required packaging tool.
@@ -54,6 +55,7 @@ pkgs+=(net-tools) # Dependency for debugging network issues.
5455
pkgs+=(ninja-build) # Required build tool.
5556
pkgs+=(python3-venv) # Python environment management tool.
5657
pkgs+=(python3-pip) # Package manager for Python applications.
58+
pkgs+=(rustc) # Rust compiler.
5759
pkgs+=(vim) # Text editor.
5860
pkgs+=(wget) # Required build tool.
5961
apt-get update

docker/rhel/Dockerfile

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,14 @@ cd ..
191191
rm -rf test
192192
EOF
193193

194+
# Add rust installation. Native rust package conflicts with gcc
195+
RUN <<EOF
196+
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
197+
. ~/.bashrc
198+
rustc -V
199+
cargo -V
200+
EOF
201+
194202
# ===================== CLANG IMAGE =====================
195203
FROM base AS clang
196204

@@ -266,3 +274,11 @@ cd test && ./run.sh clang
266274
cd ..
267275
rm -rf test
268276
EOF
277+
278+
# Add rust installation. Native rust package conflicts with gcc
279+
RUN <<EOF
280+
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
281+
. ~/.bashrc
282+
rustc -V
283+
cargo -V
284+
EOF

docker/ubuntu/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ RUN <<EOF
2727
pkgs=()
2828
pkgs+=(ca-certificates) # Enable TLS verification for HTTPS connections by providing trusted root certificates.
2929
pkgs+=(binutils-gold) # Required build tool.
30+
pkgs+=(cargo) # Package manager for Rust applications.
3031
pkgs+=(curl) # Dependency for tools requiring downloading data.
3132
pkgs+=(dpkg-dev) # Required packaging tool.
3233
pkgs+=(file) # Required packaging tool.
@@ -40,6 +41,7 @@ pkgs+=(net-tools) # Dependency for debugging network issues.
4041
pkgs+=(ninja-build) # Required build tool.
4142
pkgs+=(python3-venv) # Python environment management tool.
4243
pkgs+=(python3-pip) # Package manager for Python applications.
44+
pkgs+=(rustc) # Rust compiler.
4345
pkgs+=(vim) # Text editor.
4446
pkgs+=(wget) # Required build tool.
4547
apt-get update

0 commit comments

Comments
 (0)