Build Container Image with Podman¶
1. Build Images.¶
使用命令
podman build -t TAGS .
- 对于docker,只需要将
podman
换成docker
。
2. 对于跨平台构建¶
使用命令
podman build --platform=linux/arm/v7 -t TAGS .
此处以arm/v7
为例。
3. 将Image推送到DockerHub¶
使用下列命令,将username
和password
替换为实际的用户名和密码
podman push --creds username:password \
docker.io/library/IMAGENAME:latest \
docker.io://ACCOUNT/IMAGENAME:latest