feat:support multi platform
Some checks failed
build-docker-images-for-multi-latest-release / build-and-push (push) Failing after 3m45s
Some checks failed
build-docker-images-for-multi-latest-release / build-and-push (push) Failing after 3m45s
This commit is contained in:
parent
bfbce4dde8
commit
4659271756
@ -1,4 +1,4 @@
|
||||
name: build-docker-images-for-latest-release-github-ver
|
||||
name: build-docker-images-for-multi-latest-release
|
||||
|
||||
on:
|
||||
push:
|
||||
@ -76,13 +76,14 @@ jobs:
|
||||
echo "DOCKER_CLIENT_TIMEOUT=300" >> $GITHUB_ENV
|
||||
echo "DOCKER_BUILD_TIMEOUT=300" >> $GITHUB_ENV
|
||||
|
||||
# Build and push the Docker image for all platforms
|
||||
# Build and push the Docker image for all platforms (including multi-architecture support)
|
||||
- name: Build and Push Multi-Platform Docker Image
|
||||
uses: http://fly6516.synology.me:4000/docker/build-push-action@v4
|
||||
with:
|
||||
push: true
|
||||
tags: fly6516.synology.me:8080/multilang:latest
|
||||
context: .
|
||||
file: ./Dockerfile # Ensure this points to the correct Dockerfile location
|
||||
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
||||
|
||||
# Optional: Verify the pushed image
|
||||
|
@ -9,6 +9,11 @@ FROM fly6516.synology.me:8080/ubuntu:20.04
|
||||
# 设置环境变量
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
# 安装 QEMU 模拟器,支持多架构构建
|
||||
RUN apt-get update && apt-get install -y \
|
||||
qemu-user-static \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# 使用南京大学的 apt 源
|
||||
# RUN sed -i 's/archive.ubuntu.com/mirrors.nju.edu.cn/g' /etc/apt/sources.list
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user