[gha] test auth changes

This commit is contained in:
R4SAS 2021-06-17 13:36:43 +03:00 committed by GitHub
parent f3746a4351
commit 03d9c722b4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2,27 +2,44 @@ name: Build Docker containers
on: push
env:
IMAGE_NAME: i2pd
jobs:
docker:
name: For ${{ matrix.platform }}
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
strategy:
fail-fast: true
fail-fast: false
matrix:
platform: ['linux/amd64', 'linux/386', 'linux/arm64', 'linux/arm/v7']
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Push image
run: |
IMAGE_ID=ghcr.io/${{ github.repository_owner }}/$IMAGE_NAME
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
- name: Build and push
uses: docker/build-push-action@v2
with:
@ -30,4 +47,4 @@ jobs:
file: ./contrib/docker/Dockerfile
platforms: ${{ matrix.platform }}
push: true
tags: ghcr.io/purplei2p/i2pd:latest
tags: $IMAGE_ID:latest