Jelajahi Sumber

Move migrations to Github Action (#2978)

* move migrate to github actions

* move migrate to github actions
Stefan McShane 3 tahun lalu
induk
melakukan
8627a798f6
1 mengubah file dengan 9 tambahan dan 0 penghapusan
  1. 9 0
      .github/workflows/production.yaml

+ 9 - 0
.github/workflows/production.yaml

@@ -58,6 +58,15 @@ jobs:
       - name: Push
         run: |
           docker push gcr.io/porter-dev-273614/porter:latest
+      - name: Run Migrations
+        env:
+          DB_HOST: ${{ secrets.DB_HOST }}
+          DB_PORT: ${{ secrets.DB_PORT }}
+          DB_USER: ${{ secrets.DB_USER }}
+          DB_PASS: ${{ secrets.DB_PASS }}
+          DB_NAME: ${{ secrets.DB_NAME }}
+        run: |
+          ./bin/migrate
       - name: Deploy to cluster
         run: |
           aws eks --region ${{ secrets.AWS_REGION }} update-kubeconfig --name production-2