init
This commit is contained in:
13
build.sh
Normal file
13
build.sh
Normal file
@@ -0,0 +1,13 @@
|
||||
#!/bin/bash
|
||||
|
||||
# 创建并启用支持多平台的 buildx 构建器
|
||||
docker buildx create --name multiarch-builder --driver docker-container --use
|
||||
docker buildx inspect --bootstrap
|
||||
|
||||
# 现在可以一次性构建并推送多平台镜像
|
||||
docker buildx build --platform linux/amd64,linux/arm64 \
|
||||
-f Dockerfile \
|
||||
-t yhl452493373/html2pdf-server:latest \
|
||||
--push .
|
||||
|
||||
echo "多平台镜像构建并推送完成"
|
||||
Reference in New Issue
Block a user