aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows/build-deploy.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/build-deploy.yml')
-rw-r--r--.github/workflows/build-deploy.yml3
1 files changed, 2 insertions, 1 deletions
diff --git a/.github/workflows/build-deploy.yml b/.github/workflows/build-deploy.yml
index 2582a4113..f38686426 100644
--- a/.github/workflows/build-deploy.yml
+++ b/.github/workflows/build-deploy.yml
@@ -44,7 +44,7 @@ jobs:
with:
context: .
file: ./Dockerfile
- push: true
+ push: ${{ github.ref == 'refs/heads/main' }}
cache-from: type=registry,ref=ghcr.io/python-discord/bot:latest
cache-to: type=inline
tags: |
@@ -57,6 +57,7 @@ jobs:
name: Deploy
needs: build
runs-on: ubuntu-latest
+ if: ${{ github.ref == 'refs/heads/main' }}
environment: production
steps:
- name: Checkout Kubernetes repository