Skip to content

Commit

Permalink
Added Github Action to deploy Helm Chart
Browse files Browse the repository at this point in the history
  • Loading branch information
tgreenwood committed Mar 29, 2024
1 parent 7b71c45 commit b926e4c
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/deploy_helm_chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,15 @@ jobs:
run: |
echo ${{ secrets.GITHUB_TOKEN }} | helm registry login ${{ env.HELM_REGISTRY }} --username ${{ github.repository_owner }} --password-stdin
- name: Delete StatefulSet to force re-deploy
- name: Delete StatefulSet (if exists) to force re-deploy
run: |
kubectl delete statefulset fairspace --namespace fairspace-${{ env.ENVIRONMENT }} --cascade=orphan
# Check if the StatefulSet exists
if kubectl get statefulset fairspace --namespace fairspace-${{ env.ENVIRONMENT }} &> /dev/null; then
kubectl delete statefulset fairspace --namespace fairspace-${{ env.ENVIRONMENT }} --cascade=orphan
echo "StatefulSet fairspace deleted."
else
echo "StatefulSet fairspace does not exist."
fi
- name: Deploy Helm chart
run: |
Expand Down

0 comments on commit b926e4c

Please sign in to comment.