mirror of
https://github.com/Fishwaldo/docker-rsync.git
synced 2025-07-04 11:48:20 +00:00
Update main.yml
This commit is contained in:
parent
a9fd383af2
commit
00dd57776b
1 changed files with 30 additions and 8 deletions
38
.github/workflows/main.yml
vendored
38
.github/workflows/main.yml
vendored
|
@ -13,15 +13,37 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
- name: Docker meta
|
||||||
|
id: meta
|
||||||
|
uses: docker/metadata-action@v3
|
||||||
|
with:
|
||||||
|
# list of Docker images to use as base name for tags
|
||||||
|
images: |
|
||||||
|
ghcr.io/fishwaldo/docker-rsync
|
||||||
|
# generate Docker tags based on the following events/attributes
|
||||||
|
tags: |
|
||||||
|
type=schedule
|
||||||
|
type=ref,event=branch
|
||||||
|
type=ref,event=pr
|
||||||
|
type=semver,pattern={{version}}
|
||||||
|
type=semver,pattern={{major}}.{{minor}}
|
||||||
|
type=semver,pattern={{major}}
|
||||||
|
type=sha
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
uses: docker/setup-qemu-action@v1
|
uses: docker/setup-qemu-action@v1
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v1
|
uses: docker/setup-buildx-action@v1
|
||||||
- name: Available platforms
|
- name: Login to DockerHub
|
||||||
run: echo ${{ steps.buildx.outputs.platforms }}
|
uses: docker/login-action@v1
|
||||||
- name: Run Buildx
|
if: github.event_name != 'pull_request'
|
||||||
run: |
|
with:
|
||||||
docker buildx build \
|
registry: ghcr.io
|
||||||
--platform linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64 \
|
username: ${{ github.repository_owner }}
|
||||||
--output "type=image,push=false" \
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
--file ./Dockerfile .
|
- name: Build and push
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
platforms: linux/amd64,linux/arm64
|
||||||
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue