ci: push docker images to dockerhub too.

This commit is contained in:
evazion
2021-09-07 06:33:51 -05:00
parent 266192c599
commit 291758ddb7

View File

@@ -30,6 +30,7 @@ jobs:
uses: docker/setup-buildx-action@v1
# https://github.com/docker/login-action
# https://github.com/docker/build-push-action/blob/master/docs/advanced/push-multi-registries.md
- name: Login to Github Container Registry
uses: docker/login-action@v1
with:
@@ -37,13 +38,21 @@ jobs:
username: ${{ github.repository_owner }}
password: ${{ github.token }}
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
# Generate Docker tags from Git tags.
# https://github.com/docker/metadata-action
- name: Generate Docker tags
uses: docker/metadata-action@v3
id: metadata
with:
images: ghcr.io/${{ github.repository }}
images: |
docker.io/evazion/danbooru
ghcr.io/danbooru/danbooru
tags: |
type=sha,format=short,prefix=
type=sha,format=long,prefix=