Skip to content

Commit

Permalink
feat: bump to ubuntu:24.04
Browse files Browse the repository at this point in the history
  • Loading branch information
endersonmaia committed Sep 9, 2024
1 parent 99252c2 commit a1c1d9e
Show file tree
Hide file tree
Showing 6 changed files with 68 additions and 56 deletions.
26 changes: 14 additions & 12 deletions cpp-low-level/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
# syntax=docker.io/docker/dockerfile:1
FROM --platform=linux/riscv64 ubuntu:22.04 AS builder
FROM --platform=linux/riscv64 ubuntu:24.04 AS base

RUN apt-get update

FROM base AS builder

ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
autoconf \
automake \
build-essential \
ca-certificates \
curl \
libtool \
wget
autoconf=2.71-3 \
automake=1:1.16.5-1.3ubuntu1 \
build-essential=12.10ubuntu1 \
ca-certificates=20240203 \
curl=8.5.0-2ubuntu10.3 \
libtool=2.4.7-7build1 \
wget=1.21.4-1ubuntu4.1
rm -rf /var/lib/apt/lists/*
EOF

Expand All @@ -21,7 +24,7 @@ WORKDIR /opt/cartesi/dapp
COPY . .
RUN make

FROM --platform=linux/riscv64 ubuntu:22.04
FROM base

ARG MACHINE_EMULATOR_TOOLS_VERSION=0.14.1
ADD https://github.com/cartesi/machine-emulator-tools/releases/download/v${MACHINE_EMULATOR_TOOLS_VERSION}/machine-emulator-tools-v${MACHINE_EMULATOR_TOOLS_VERSION}.deb /
Expand All @@ -34,9 +37,8 @@ LABEL io.cartesi.rollups.ram_size=128Mi
ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
busybox-static=1:1.30.1-7ubuntu3
busybox-static=1:1.36.1-6ubuntu3.1
rm -rf /var/lib/apt/lists/* /var/log/* /var/cache/*
useradd --create-home --user-group dapp
EOF
Expand Down
26 changes: 14 additions & 12 deletions cpp/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,26 +1,29 @@
# syntax=docker.io/docker/dockerfile:1
FROM --platform=linux/riscv64 ubuntu:22.04 AS builder
FROM --platform=linux/riscv64 ubuntu:24.04 AS base

RUN apt-get update

FROM base AS builder

ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
autoconf \
automake \
build-essential \
ca-certificates \
curl \
libtool \
wget
autoconf=2.71-3 \
automake=1:1.16.5-1.3ubuntu1 \
build-essential=12.10ubuntu1 \
ca-certificates=20240203 \
curl=8.5.0-2ubuntu10.3 \
libtool=2.4.7-7build1 \
wget=1.21.4-1ubuntu4.1
rm -rf /var/lib/apt/lists/*
EOF

WORKDIR /opt/cartesi/dapp
COPY . .
RUN make

FROM --platform=linux/riscv64 ubuntu:22.04
FROM base

ARG MACHINE_EMULATOR_TOOLS_VERSION=0.14.1
ADD https://github.com/cartesi/machine-emulator-tools/releases/download/v${MACHINE_EMULATOR_TOOLS_VERSION}/machine-emulator-tools-v${MACHINE_EMULATOR_TOOLS_VERSION}.deb /
Expand All @@ -33,9 +36,8 @@ LABEL io.cartesi.rollups.ram_size=128Mi
ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
busybox-static=1:1.30.1-7ubuntu3
busybox-static=1:1.36.1-6ubuntu3.1
rm -rf /var/lib/apt/lists/* /var/log/* /var/cache/*
useradd --create-home --user-group dapp
EOF
Expand Down
19 changes: 11 additions & 8 deletions go/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
# syntax=docker.io/docker/dockerfile:1
FROM ubuntu:22.04 AS build-stage
FROM ubuntu:24.04 AS build-stage

ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt update
apt install -y --no-install-recommends \
build-essential=12.9ubuntu3 \
ca-certificates \
g++-riscv64-linux-gnu=4:11.2.0--1ubuntu1 \
wget
build-essential=12.10ubuntu1 \
ca-certificates=20240203 \
g++-riscv64-linux-gnu=4:13.2.0-7ubuntu1 \
wget=1.21.4-1ubuntu4.1
EOF

ARG GOVERSION=1.20.5
Expand All @@ -30,7 +30,11 @@ COPY src .
RUN make

# runtime stage: produces final image that will be executed
FROM --platform=linux/riscv64 ubuntu:22.04
FROM --platform=linux/riscv64 ubuntu:24.04 AS base

RUN apt-get update

FROM base

ARG MACHINE_EMULATOR_TOOLS_VERSION=0.14.1
ADD https://github.com/cartesi/machine-emulator-tools/releases/download/v${MACHINE_EMULATOR_TOOLS_VERSION}/machine-emulator-tools-v${MACHINE_EMULATOR_TOOLS_VERSION}.deb /
Expand All @@ -43,9 +47,8 @@ LABEL io.cartesi.rollups.ram_size=128Mi
ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
busybox-static=1:1.30.1-7ubuntu3
busybox-static=1:1.36.1-6ubuntu3.1
rm -rf /var/lib/apt/lists/* /var/log/* /var/cache/*
useradd --create-home --user-group dapp
EOF
Expand Down
21 changes: 12 additions & 9 deletions lua/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,22 +1,25 @@
# syntax=docker.io/docker/dockerfile:1
FROM --platform=linux/riscv64 ubuntu:22.04 AS builder
FROM --platform=linux/riscv64 ubuntu:24.04 AS base

RUN apt-get update

FROM base AS builder

ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
build-essential=12.9ubuntu3 \
lua5.4=5.4.4-1 \
liblua5.4-dev=5.4.4-1 \
build-essential=12.10ubuntu1 \
liblua5.4-dev=5.4.6-3build2 \
lua5.4=5.4.6-3build2 \
luarocks=3.8.0+dfsg1-1
rm -rf /var/lib/apt/lists/*

luarocks install --lua-version=5.4 luasocket 3.1.0-1
luarocks install --lua-version=5.4 dkjson 2.6-1
EOF

FROM --platform=linux/riscv64 ubuntu:22.04
FROM base

ARG MACHINE_EMULATOR_TOOLS_VERSION=0.14.1
ADD https://github.com/cartesi/machine-emulator-tools/releases/download/v${MACHINE_EMULATOR_TOOLS_VERSION}/machine-emulator-tools-v${MACHINE_EMULATOR_TOOLS_VERSION}.deb /
Expand All @@ -31,9 +34,9 @@ RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
busybox-static=1:1.30.1-7ubuntu3 \
liblua5.4-dev=5.4.4-1 \
lua5.4=5.4.4-1
busybox-static=1:1.36.1-6ubuntu3.1 \
liblua5.4-dev=5.4.6-3build2 \
lua5.4=5.4.6-3build2
rm -rf /var/lib/apt/lists/* /var/log/* /var/cache/*
useradd --create-home --user-group dapp
EOF
Expand Down
13 changes: 6 additions & 7 deletions ruby/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# syntax=docker.io/docker/dockerfile:1
FROM --platform=linux/riscv64 ubuntu:22.04 AS base
FROM --platform=linux/riscv64 ubuntu:24.04 AS base

RUN apt-get update

Expand All @@ -9,9 +9,9 @@ ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get install -y --no-install-recommends \
build-essential=12.9ubuntu3 \
ruby-dev="1:3.0~exp1" \
ruby="1:3.0~exp1"
build-essential=12.10ubuntu1 \
ruby-dev="1:3.2~ubuntu1" \
ruby="1:3.2~ubuntu1"
rm -rf /var/apt/lists/*
gem install bundler --no-document
EOF
Expand All @@ -37,10 +37,9 @@ LABEL io.cartesi.rollups.ram_size=128Mi
ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
busybox-static=1:1.30.1-7ubuntu3 \
ruby="1:3.0~exp1"
busybox-static=1:1.36.1-6ubuntu3.1 \
ruby="1:3.2~ubuntu1"
rm -rf /var/lib/apt/lists/* /var/log/* /var/cache/*
useradd --create-home --user-group dapp
EOF
Expand Down
19 changes: 11 additions & 8 deletions rust/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# syntax=docker.io/docker/dockerfile:1
FROM ubuntu:22.04 AS builder
FROM ubuntu:24.04 AS builder

ENV RUSTUP_HOME=/usr/local/rustup \
CARGO_HOME=/usr/local/cargo \
Expand All @@ -11,10 +11,10 @@ RUN <<EOF
set -e
apt update
apt install -y --no-install-recommends \
build-essential=12.9ubuntu3 \
ca-certificates=20230311ubuntu0.22.04.1 \
g++-riscv64-linux-gnu=4:11.2.0--1ubuntu1 \
wget=1.21.2-2ubuntu1
build-essential=12.10ubuntu1 \
ca-certificates=20240203 \
g++-riscv64-linux-gnu=4:13.2.0-7ubuntu1 \
wget=1.21.4-1ubuntu4.1
EOF

RUN set -eux; \
Expand Down Expand Up @@ -43,7 +43,11 @@ WORKDIR /opt/cartesi/dapp
COPY . .
RUN cargo build --release

FROM --platform=linux/riscv64 ubuntu:22.04
FROM --platform=linux/riscv64 ubuntu:24.04 AS base

RUN apt-get update

FROM base

ARG MACHINE_EMULATOR_TOOLS_VERSION=0.14.1
ADD https://github.com/cartesi/machine-emulator-tools/releases/download/v${MACHINE_EMULATOR_TOOLS_VERSION}/machine-emulator-tools-v${MACHINE_EMULATOR_TOOLS_VERSION}.deb /
Expand All @@ -56,9 +60,8 @@ LABEL io.cartesi.rollups.ram_size=128Mi
ARG DEBIAN_FRONTEND=noninteractive
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
busybox-static=1:1.30.1-7ubuntu3
busybox-static=1:1.36.1-6ubuntu3.1
rm -rf /var/lib/apt/lists/* /var/log/* /var/cache/*
useradd --create-home --user-group dapp
EOF
Expand Down

0 comments on commit a1c1d9e

Please sign in to comment.