Change github workflow to push a forked image
This commit is contained in:
parent
eb63f6ebd7
commit
5cfae11de2
1 changed files with 7 additions and 25 deletions
32
.github/workflows/dockerhub.yml
vendored
32
.github/workflows/dockerhub.yml
vendored
|
@ -27,7 +27,7 @@ jobs:
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
- name: Retrieve version
|
- name: Retrieve version
|
||||||
run: echo "GIT_DESCRIBE=$(git describe --tags)" >> $GITHUB_ENV
|
run: echo "GIT_DESCRIBE=$(git describe --tags)" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
@ -36,13 +36,11 @@ jobs:
|
||||||
uses: docker/metadata-action@v3
|
uses: docker/metadata-action@v3
|
||||||
with:
|
with:
|
||||||
images: |
|
images: |
|
||||||
ghcr.io/nginx-proxy/nginx-proxy
|
hiqdev/nginx-proxy
|
||||||
nginxproxy/nginx-proxy
|
|
||||||
jwilder/nginx-proxy
|
|
||||||
tags: |
|
tags: |
|
||||||
type=semver,pattern={{version}}
|
type=semver,pattern={{version}}
|
||||||
type=semver,pattern={{major}}.{{minor}}
|
type=semver,pattern={{major}}.{{minor}}
|
||||||
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/main' }}
|
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }}
|
||||||
labels: |
|
labels: |
|
||||||
org.opencontainers.image.authors=Nicolas Duchon <nicolas.duchon@gmail.com> (@buchdag), Jason Wilder
|
org.opencontainers.image.authors=Nicolas Duchon <nicolas.duchon@gmail.com> (@buchdag), Jason Wilder
|
||||||
org.opencontainers.image.version=${{ env.GIT_DESCRIBE }}
|
org.opencontainers.image.version=${{ env.GIT_DESCRIBE }}
|
||||||
|
@ -54,17 +52,10 @@ jobs:
|
||||||
uses: docker/setup-buildx-action@v1
|
uses: docker/setup-buildx-action@v1
|
||||||
|
|
||||||
- name: Login to DockerHub
|
- name: Login to DockerHub
|
||||||
uses: docker/login-action@v1
|
uses: docker/login-action@v1
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Log in to GitHub Container Registry
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
registry: ghcr.io
|
|
||||||
username: ${{ github.actor }}
|
|
||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
|
|
||||||
- name: Build and push the Debian based image
|
- name: Build and push the Debian based image
|
||||||
id: docker_build_debian
|
id: docker_build_debian
|
||||||
|
@ -89,7 +80,7 @@ jobs:
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
- name: Retrieve version
|
- name: Retrieve version
|
||||||
run: echo "GIT_DESCRIBE=$(git describe --tags)" >> $GITHUB_ENV
|
run: echo "GIT_DESCRIBE=$(git describe --tags)" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
@ -98,13 +89,11 @@ jobs:
|
||||||
uses: docker/metadata-action@v3
|
uses: docker/metadata-action@v3
|
||||||
with:
|
with:
|
||||||
images: |
|
images: |
|
||||||
ghcr.io/nginx-proxy/nginx-proxy
|
hiqdev/nginx-proxy
|
||||||
nginxproxy/nginx-proxy
|
|
||||||
jwilder/nginx-proxy
|
|
||||||
tags: |
|
tags: |
|
||||||
type=semver,suffix=-alpine,pattern={{version}}
|
type=semver,suffix=-alpine,pattern={{version}}
|
||||||
type=semver,suffix=-alpine,pattern={{major}}.{{minor}}
|
type=semver,suffix=-alpine,pattern={{major}}.{{minor}}
|
||||||
type=raw,value=alpine,enable=${{ github.ref == 'refs/heads/main' }}
|
type=raw,value=alpine,enable=${{ github.ref == 'refs/heads/master' }}
|
||||||
labels: |
|
labels: |
|
||||||
org.opencontainers.image.authors=Nicolas Duchon <nicolas.duchon@gmail.com> (@buchdag), Jason Wilder
|
org.opencontainers.image.authors=Nicolas Duchon <nicolas.duchon@gmail.com> (@buchdag), Jason Wilder
|
||||||
org.opencontainers.image.version=${{ env.GIT_DESCRIBE }}
|
org.opencontainers.image.version=${{ env.GIT_DESCRIBE }}
|
||||||
|
@ -121,13 +110,6 @@ jobs:
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Log in to GitHub Container Registry
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
registry: ghcr.io
|
|
||||||
username: ${{ github.actor }}
|
|
||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
|
|
||||||
- name: Build and push the Alpine based image
|
- name: Build and push the Alpine based image
|
||||||
id: docker_build_alpine
|
id: docker_build_alpine
|
||||||
|
|
Loading…
Reference in a new issue