File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1818
1919jobs :
2020 build-and-push :
21- # 回退到标准的 AMD64 Runner,构建速度较快,但产物不支持在 ARM 机器上原生运行
21+ # 使用标准的 ubuntu-latest ( AMD64) 并通过 QEMU 模拟构建 linux/arm64
2222 runs-on : ubuntu-latest
2323 permissions :
2424 contents : read
3535 distribution : ' temurin'
3636 cache : ' maven'
3737
38+ # 必须启用 QEMU 才能在 AMD64 机器上构建 ARM64 镜像
39+ - name : Set up QEMU
40+ uses : docker/setup-qemu-action@v3
41+
3842 - name : Set up Docker Buildx
3943 uses : docker/setup-buildx-action@v3
4044
6064 context : .
6165 file : ./docker/native-image/Dockerfile
6266 push : true
63- platforms : linux/amd64
67+ platforms : linux/arm64
6468 tags : ${{ steps.meta.outputs.tags }}
6569 labels : ${{ steps.meta.outputs.labels }}
6670 cache-from : type=gha
Original file line number Diff line number Diff line change 1717``` bash
1818docker compose -f docker/native-image/docker-compose.yml pull
1919docker compose -f docker/native-image/docker-compose.yml up -d
20+
21+
22+ docker compose up -d
2023```
2124
2225## 二、当前镜像说明
You can’t perform that action at this time.
0 commit comments