From 10425c90f6b8c0a7e590babc3c48535f496101d7 Mon Sep 17 00:00:00 2001 From: Mihoub Debache Date: Wed, 24 Apr 2024 14:24:05 +0200 Subject: [PATCH] feat(ci): add deploy workflow --- .github/workflows/staging.yml | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/.github/workflows/staging.yml b/.github/workflows/staging.yml index 527a4f2..e120868 100644 --- a/.github/workflows/staging.yml +++ b/.github/workflows/staging.yml @@ -5,8 +5,8 @@ on: branches: - staging env: - DEPLOYMENT: ticket-office - DEPLOYMENT_NAMESPACE: ticket-office + # DEPLOYMENT: ticket-office + # DEPLOYMENT_NAMESPACE: ticket-office DEPLOYMENT_URL: https://ticket-office.staging.dataesr.ovh MM_NOTIFICATION_CHANNEL: bots @@ -39,23 +39,23 @@ jobs: IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') docker push $IMAGE_ID:staging - # deploy: - # name: 💭 Update staging deployment - # runs-on: ubuntu-latest - # needs: publish-ghcr - # steps: - # - name: Deploy to Cluster - # id: kubectl-deploy - # uses: dataesr/kubectl-deploy@v1.1 - # env: - # KUBE_CONFIG: ${{ secrets.KUBE_CONFIG_DOAD_STAGING }} - # with: - # namespace: ${{ env.DEPLOYMENT_NAMESPACE }} - # restart: ${{ env.DEPLOYMENT }} + deploy: + name: 💭 Update staging deployment + runs-on: ubuntu-latest + needs: publish-ghcr + steps: + - name: Deploy to Cluster + id: kubectl-deploy + uses: dataesr/kubectl-deploy@v1.1 + env: + KUBE_CONFIG: ${{ secrets.KUBE_CONFIG_DOAD_STAGING }} + with: + namespace: ${{ env.DEPLOYMENT_NAMESPACE }} + restart: ${{ env.DEPLOYMENT }} notify: name: 📢 Notify in mattermost channel - needs: publish-ghcr + needs: deploy if: always() runs-on: ubuntu-latest steps: