parent
76b3dd6a93
commit
0f9ce9b711
2 changed files with 7 additions and 8 deletions
|
|
@ -3,7 +3,7 @@ name: Production Deployment
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- production
|
- main
|
||||||
|
|
||||||
env:
|
env:
|
||||||
REGISTRY: git.mcintire.me
|
REGISTRY: git.mcintire.me
|
||||||
|
|
@ -287,7 +287,7 @@ jobs:
|
||||||
git config user.email "actions@git.mcintire.me"
|
git config user.email "actions@git.mcintire.me"
|
||||||
git add k8s/deployment.yaml
|
git add k8s/deployment.yaml
|
||||||
git commit -m "chore: update production image to ${IMAGE_TAG} [skip ci]" || echo "No changes to commit"
|
git commit -m "chore: update production image to ${IMAGE_TAG} [skip ci]" || echo "No changes to commit"
|
||||||
git push origin production
|
git push origin HEAD:production
|
||||||
|
|
||||||
- name: Deployment summary
|
- name: Deployment summary
|
||||||
run: |
|
run: |
|
||||||
|
|
|
||||||
|
|
@ -1,22 +1,20 @@
|
||||||
name: Deploy to Staging
|
name: Deploy to Staging
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
pull_request:
|
||||||
branches:
|
types: [opened, synchronize, reopened]
|
||||||
- main
|
|
||||||
|
|
||||||
env:
|
env:
|
||||||
DOCKER_BUILDKIT: 1
|
DOCKER_BUILDKIT: 1
|
||||||
DOCKER_TLS_CERTDIR: ""
|
DOCKER_TLS_CERTDIR: ""
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.ref }}
|
group: ${{ github.workflow }}-${{ github.head_ref }}
|
||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
deploy-staging:
|
deploy-staging:
|
||||||
name: Deploy to Dokku Staging
|
name: Deploy to Dokku Staging
|
||||||
if: github.ref == 'refs/heads/main'
|
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-22.04
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
|
|
@ -36,5 +34,6 @@ jobs:
|
||||||
ssh dokku@204.110.191.231 apps:unlock towerops || true
|
ssh dokku@204.110.191.231 apps:unlock towerops || true
|
||||||
git remote add dokku dokku@204.110.191.231:towerops || true
|
git remote add dokku dokku@204.110.191.231:towerops || true
|
||||||
git fetch dokku || true
|
git fetch dokku || true
|
||||||
git push dokku main:main --force
|
# Deploy the PR branch to staging
|
||||||
|
git push dokku HEAD:main --force
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue