mirror of
https://github.com/tdlight-team/tdlight-telegram-bot-api.git
synced 2025-01-13 13:27:32 +01:00
Don't push Docker images if the event is a pull request
This commit is contained in:
parent
9b14e5c1b8
commit
f047ece20c
4
.github/workflows/docker.yml
vendored
4
.github/workflows/docker.yml
vendored
@ -81,6 +81,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Login to ghcr registry
|
- name: Login to ghcr registry
|
||||||
uses: docker/login-action@v1
|
uses: docker/login-action@v1
|
||||||
|
if: ${{ ! github.event_name == 'pull_request' }}
|
||||||
with:
|
with:
|
||||||
registry: ghcr.io
|
registry: ghcr.io
|
||||||
username: ${{ secrets.GH_USERNAME }}
|
username: ${{ secrets.GH_USERNAME }}
|
||||||
@ -88,6 +89,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Login to Docker Hub registry
|
- name: Login to Docker Hub registry
|
||||||
uses: docker/login-action@v1
|
uses: docker/login-action@v1
|
||||||
|
if: ${{ ! github.event_name == 'pull_request' }}
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}
|
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}
|
||||||
@ -106,6 +108,7 @@ jobs:
|
|||||||
tdlightbotapi:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }}
|
tdlightbotapi:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }}
|
||||||
|
|
||||||
- name: Tag and push image
|
- name: Tag and push image
|
||||||
|
if: ${{ ! github.event_name == 'pull_request' }}
|
||||||
run: |
|
run: |
|
||||||
docker tag tdlightbotapi:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }} ${{ env.IMAGE_TAG }}:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }}
|
docker tag tdlightbotapi:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }} ${{ env.IMAGE_TAG }}:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }}
|
||||||
docker tag tdlightbotapi:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }} ${{ env.IMAGE_TAG }}:${{ env.VERSION }}-${{ env.SAFE_ARCH }}
|
docker tag tdlightbotapi:${{ env.HASH_VERSION }}-${{ env.SAFE_ARCH }} ${{ env.IMAGE_TAG }}:${{ env.VERSION }}-${{ env.SAFE_ARCH }}
|
||||||
@ -130,6 +133,7 @@ jobs:
|
|||||||
push-manifest:
|
push-manifest:
|
||||||
name: Create and push multi-arch Docker manifest
|
name: Create and push multi-arch Docker manifest
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
if: ${{ ! github.event_name == 'pull_request' }}
|
||||||
env:
|
env:
|
||||||
DOCKER_CLI_EXPERIMENTAL: enabled
|
DOCKER_CLI_EXPERIMENTAL: enabled
|
||||||
needs: build
|
needs: build
|
||||||
|
Loading…
x
Reference in New Issue
Block a user