fix: update:catalog #32
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy to Staging | |
concurrency: stage | |
on: | |
push: | |
branches: [master, gql] | |
jobs: | |
build-push: | |
name: Build and Push Images | |
uses: ./.github/workflows/cd.yaml | |
with: | |
tag: latest | |
secrets: inherit | |
deploy: | |
name: Deploy with SSH | |
needs: [build-push] | |
runs-on: ubuntu-latest | |
environment: staging | |
steps: | |
- name: SSH and Helm Install | |
uses: appleboy/[email protected] | |
with: | |
host: ${{ secrets.SSH_HOST }} | |
username: root | |
key: ${{ secrets.SSH_KEY }} | |
script: | | |
cd ./infra | |
if helm status bt-stage-app ; then | |
kubectl rollout restart deployment bt-stage-app-backend | |
kubectl rollout restart deployment bt-stage-app-frontend | |
else | |
helm install bt-stage-app ./app --namespace=bt \ | |
--set env=stage \ | |
--set frontend.image.tag=latest \ | |
--set backend.image.tag=latest \ | |
--set host=staging.stanfurdtime.com \ | |
--set mongoUri=mongodb://bt-stage-mongo-mongodb.bt.svc.cluster.local:27017/bt \ | |
--set redisUri=redis://bt-stage-redis-master.bt.svc.cluster.local:6379 | |
fi |