-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of github.com:element36-io/test-r0
- Loading branch information
Showing
3 changed files
with
48 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,54 @@ | ||
name: Docker Build | ||
name: Buildx Action | ||
|
||
on: | ||
push | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
runs-on: macos-latest | ||
permissions: | ||
contents: write | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
platform: | ||
- linux/amd64 | ||
- linux/arm64 | ||
|
||
# strategy: | ||
# fail-fast: false | ||
# matrix: | ||
# # os: | ||
# # - macos-latest # https://docs.github.com/en/actions/using-jobs/using-a-matrix-for-your-jobs | ||
# platform: | ||
# - linux/arm64 | ||
|
||
steps: | ||
- | ||
name: Prepare | ||
run: | | ||
platform=${{ matrix.platform }} | ||
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV | ||
# - name: Prepare | ||
# run: | | ||
# platform=${{ matrix.platform }} | ||
# echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV | ||
|
||
|
||
- name: Check out code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
# - name: Set up QEMU | ||
# uses: docker/setup-qemu-action@v3 | ||
- | ||
name: Set up Docker | ||
uses: crazy-max/ghaction-setup-docker@v3 | ||
# uses: crazy-max/ghaction-setup-containerd@v3 | ||
|
||
- name: Login to DockerHub | ||
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a | ||
with: | ||
username: ${{ secrets.DOCKER_USERNAME }} | ||
password: ${{ secrets.DOCKER_PASSWORD }} | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- | ||
name: Build and push by digest | ||
name: Build | ||
id: build | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
platforms: ${{ matrix.platform }} | ||
labels: ${{ steps.meta.outputs.labels }} | ||
outputs: type=image,name=${{ env.REGISTRY_IMAGE }},push-by-digest=true,name-canonical=true,push=true | ||
# platforms: ${{ matrix.platform }} | ||
# labels: ${{ steps.meta.outputs.labels }} | ||
outputs: type=image,name=${{ env.REGISTRY_IMAGE }},name-canonical=true,push=false | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,21 @@ | ||
name: Docker Build | ||
name: run.sh | ||
|
||
on: | ||
push | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
runs-on: macos-latest | ||
permissions: | ||
contents: write | ||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v3 | ||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
uses: actions/checkout@v3 | ||
|
||
- | ||
name: Set up Docker | ||
uses: crazy-max/ghaction-setup-docker@v3 | ||
# uses: crazy-max/ghaction-setup-containerd@v3 | ||
|
||
- name: Build Docker image (manual) | ||
run: ./run.sh | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters