mirror of
https://github.com/redhat-actions/buildah-build.git
synced 2025-06-08 10:01:34 +00:00
Add feature to build multi arch image
Since buildah now supports multi arch image built support (ref: https://github.com/containers/buildah/issues/1590) This feature will allow building images based on multiple architectures Signed-off-by: divyansh42 <diagrawa@redhat.com>
This commit is contained in:
parent
21e07c3197
commit
749ffdbf42
9 changed files with 39 additions and 12 deletions
|
@ -21,6 +21,7 @@ After building your image, use [push-to-registry](https://github.com/redhat-acti
|
|||
|
||||
| Input Name | Description | Default |
|
||||
| ---------- | ----------- | ------- |
|
||||
| archs | ARCH of the image to build, for multiple ARCHs seperate by a comma. For example, `"arm64,amd64"`. If running on self hosted runners then suggest running [qemu-user-static](https://github.com/marketplace/actions/docker-setup-qemu) action to install `qemu-user-static`. | `amd64`
|
||||
| build-args | Build arguments to pass to the Docker build using `--build-arg`, if using a Dockerfile that requires ARGs. Use the form `arg_name=arg_value`, and separate arguments with newlines. | None
|
||||
| context | Path to directory to use as the build context. | `.`
|
||||
| dockerfiles | The list of Dockerfile paths to perform a build using docker instructions. This is a multiline input to allow multiple Dockerfiles. | **Must be provided**
|
||||
|
@ -32,6 +33,7 @@ After building your image, use [push-to-registry](https://github.com/redhat-acti
|
|||
|
||||
| Input Name | Description | Default |
|
||||
| ---------- | ----------- | ------- |
|
||||
| archs | ARCH of the image to build, for multiple ARCHs seperate by a comma. For example, `"arm64,amd64"`. If running on self hosted runners then suggest running [qemu-user-static](https://github.com/marketplace/actions/docker-setup-qemu) action to install `qemu-user-static`. | `amd64`
|
||||
| base-image | The base image to use for the container. | **Must be provided**
|
||||
| content | Paths to files or directories to copy inside the container to create the file image. This is a multiline input to allow you to copy multiple files/directories.| None
|
||||
| context | Path to directory to use as the build context. | `.`
|
||||
|
@ -74,7 +76,7 @@ jobs:
|
|||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Buildah Action
|
||||
uses: redhat-actions/buildah-build@v2
|
||||
uses: redhat-actions/buildah-build@v3
|
||||
with:
|
||||
image: my-new-image
|
||||
tags: v1 ${{ github.sha }}
|
||||
|
@ -115,7 +117,7 @@ jobs:
|
|||
- run: mvn package
|
||||
|
||||
- name: Build Image
|
||||
uses: redhat-actions/buildah-build@v2
|
||||
uses: redhat-actions/buildah-build@v3
|
||||
with:
|
||||
base-image: docker.io/fabric8/java-alpine-openjdk11-jre
|
||||
image: my-new-image
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue