diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index decd836..d2909bc 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -17,7 +17,7 @@ jobs: include: - distro: centos-7 platform: linux/amd64 - - distro: bionic + - distro: focal platform: linux/amd64 - distro: aarch64 platform: linux/arm64 @@ -59,7 +59,7 @@ jobs: include: - distro: centos-7 platform: linux/amd64 - - distro: bionic + - distro: focal platform: linux/amd64 - distro: aarch64 platform: linux/arm64 @@ -95,7 +95,7 @@ jobs: include: - distro: centos-7 platform: linux/amd64 - - distro: bionic + - distro: focal platform: linux/amd64 - distro: aarch64 platform: linux/arm64 diff --git a/Makefile b/Makefile index e81fce3..ca31d71 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ GHCR_REPO := ghcr.io/nervosnetwork/ckb-docker-builder RUST_VERSION := rust-$(shell sed -n "s/RUST_VERSION\s*=\s*'\(.*\)'$$/\1/p" gen-dockerfiles) IMAGE_VERSION := ${RUST_VERSION} -bionic/Dockerfile: gen-dockerfiles templates/bionic.Dockerfile +focal/Dockerfile: gen-dockerfiles templates/focal.Dockerfile python3 gen-dockerfiles centos-7/Dockerfile: gen-dockerfiles templates/centos-7.Dockerfile @@ -12,10 +12,10 @@ centos-7/Dockerfile: gen-dockerfiles templates/centos-7.Dockerfile aarch64/Dockerfile: gen-dockerfiles templates/aarch64.Dockerfile python3 gen-dockerfiles -build-all: build-bionic build-centos-7 build-aarch64 +build-all: build-focal build-centos-7 build-aarch64 -build-bionic: bionic/Dockerfile - docker build -f bionic/Dockerfile --tag ${DOCKERHUB_REPO}:bionic-${IMAGE_VERSION} . +build-focal: focal/Dockerfile + docker build -f focal/Dockerfile --tag ${DOCKERHUB_REPO}:focal-${IMAGE_VERSION} . build-centos-7: centos-7/Dockerfile docker build -f centos-7/Dockerfile --tag ${DOCKERHUB_REPO}:centos-7-${IMAGE_VERSION} . @@ -23,11 +23,11 @@ build-centos-7: centos-7/Dockerfile build-aarch64: aarch64/Dockerfile docker build -f aarch64/Dockerfile --tag ${DOCKERHUB_REPO}:aarch64-${IMAGE_VERSION} . -.PHONY: build-all build-bionic build-centos-7 build-aarch64 -push-all: push-bionic push-centos-7 push-aarch64 +.PHONY: build-all build-focal build-centos-7 build-aarch64 +push-all: push-focal push-centos-7 push-aarch64 -push-bionic: build-bionic - docker push ${DOCKERHUB_REPO}:bionic-${IMAGE_VERSION} +push-focal: build-focal + docker push ${DOCKERHUB_REPO}:focal-${IMAGE_VERSION} push-centos-7: build-centos-7 docker push ${DOCKERHUB_REPO}:centos-7-${IMAGE_VERSION} @@ -35,17 +35,17 @@ push-centos-7: build-centos-7 push-aarch64: build-aarch64 docker push ${DOCKERHUB_REPO}:aarch64-${IMAGE_VERSION} -.PHONY: push-all push-bionic push-centos-7 push-aarch64 +.PHONY: push-all push-focal push-centos-7 push-aarch64 -test-all: test-bionic test-centos-7 +test-all: test-focal test-centos-7 sync-ckb: if [ -d ckb ]; then git -C ckb pull; else git clone --depth 1 https://github.com/nervosnetwork/ckb.git; fi -test-bionic: sync-ckb - docker run --rm -it -w /ckb -v "$$(pwd)/ckb:/ckb" ${DOCKERHUB_REPO}:bionic-${IMAGE_VERSION} make prod +test-focal: sync-ckb + docker run --rm -it -w /ckb -v "$$(pwd)/ckb:/ckb" ${DOCKERHUB_REPO}:focal-${IMAGE_VERSION} make prod test-centos-7: sync-ckb docker run --rm -it -w /ckb -v "$$(pwd)/ckb:/ckb" ${DOCKERHUB_REPO}:centos-7-${IMAGE_VERSION} make prod -.PHONY: test-all test-bionic test-centos-7 sync-ckb +.PHONY: test-all test-focal test-centos-7 sync-ckb diff --git a/aarch64/Dockerfile b/aarch64/Dockerfile index 0806cf1..735d286 100644 --- a/aarch64/Dockerfile +++ b/aarch64/Dockerfile @@ -1,4 +1,4 @@ -FROM arm64v8/ubuntu:20.04 +FROM arm64v8/ubuntu:22.04 RUN set -eux; \ apt-get update; \ @@ -28,7 +28,7 @@ RUN set -eux; \ echo "${RUSTUP_SHA256} *rustup-init" | sha256sum -c -; \ chmod +x rustup-init -ENV RUST_VERSION=1.85.0 +ENV RUST_VERSION=1.91.0 RUN set -eux; \ ./rustup-init -y --no-modify-path --default-toolchain $RUST_VERSION; \ diff --git a/centos-7/Dockerfile b/centos-7/Dockerfile index 61765ac..3d9d87c 100644 --- a/centos-7/Dockerfile +++ b/centos-7/Dockerfile @@ -27,7 +27,7 @@ RUN set -eux; \ echo "${RUSTUP_SHA256} *rustup-init" | sha256sum -c -; \ chmod +x rustup-init -ENV RUST_VERSION=1.85.0 +ENV RUST_VERSION=1.91.0 RUN set -eux; \ ./rustup-init -y --no-modify-path --default-toolchain $RUST_VERSION; \ diff --git a/bionic/Dockerfile b/focal/Dockerfile similarity index 96% rename from bionic/Dockerfile rename to focal/Dockerfile index ed75c0b..89ee8c7 100644 --- a/bionic/Dockerfile +++ b/focal/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:bionic +FROM ubuntu:focal RUN set -eux; \ apt-get update; \ @@ -27,7 +27,7 @@ RUN set -eux; \ echo "${RUSTUP_SHA256} *rustup-init" | sha256sum -c -; \ chmod +x rustup-init -ENV RUST_VERSION=1.85.0 +ENV RUST_VERSION=1.91.0 RUN set -eux; \ ./rustup-init -y --no-modify-path --default-toolchain $RUST_VERSION; \ diff --git a/gen-dockerfiles b/gen-dockerfiles index a391855..d8908bd 100755 --- a/gen-dockerfiles +++ b/gen-dockerfiles @@ -3,12 +3,12 @@ import os from urllib import request -RUST_VERSION = '1.85.0' +RUST_VERSION = '1.91.0' RUSTUP_VERSION = '1.27.1' DISTRIBUTIONS = { # Ubuntu - 'bionic': 'x86_64-unknown-linux-gnu', + 'focal': 'x86_64-unknown-linux-gnu', # CentOS 'centos-7': 'x86_64-unknown-linux-gnu', # Arch64 diff --git a/templates/aarch64.Dockerfile b/templates/aarch64.Dockerfile index 5d47949..09e9953 100644 --- a/templates/aarch64.Dockerfile +++ b/templates/aarch64.Dockerfile @@ -1,4 +1,4 @@ -FROM arm64v8/ubuntu:20.04 +FROM arm64v8/ubuntu:22.04 RUN set -eux; \ apt-get update; \ diff --git a/templates/bionic.Dockerfile b/templates/focal.Dockerfile similarity index 98% rename from templates/bionic.Dockerfile rename to templates/focal.Dockerfile index fd03b21..b0cae4d 100644 --- a/templates/bionic.Dockerfile +++ b/templates/focal.Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:bionic +FROM ubuntu:focal RUN set -eux; \ apt-get update; \