combine migration job with deploy

This commit is contained in:
Maidul Islam
2024-03-24 00:47:46 -04:00
parent a280e002ed
commit c67084f08d
@@ -52,7 +52,7 @@ jobs:
POSTHOG_API_KEY=${{ secrets.PUBLIC_POSTHOG_API_KEY }} POSTHOG_API_KEY=${{ secrets.PUBLIC_POSTHOG_API_KEY }}
INFISICAL_PLATFORM_VERSION=${{ steps.extract_version.outputs.version }} INFISICAL_PLATFORM_VERSION=${{ steps.extract_version.outputs.version }}
gamma-postgres-migration: gamma-deployment:
name: Run latest migration in gamma name: Run latest migration in gamma
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: [infisical-image] needs: [infisical-image]
@@ -72,16 +72,7 @@ jobs:
cd backend cd backend
npm install npm install
npm run migration:latest npm run migration:latest
gamma-deployment:
name: Deploy to gamma stage
runs-on: ubuntu-latest
needs: [gamma-postgres-migration]
environment:
name: Gamma
url: https://gamma.infisical.com
steps:
- name: ☁️ Checkout source
uses: actions/checkout@v3
- name: Configure AWS Credentials - name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4 uses: aws-actions/configure-aws-credentials@v4
with: with:
@@ -130,16 +121,6 @@ jobs:
cd backend cd backend
npm install npm install
npm run migration:latest npm run migration:latest
prod-deployment:
name: Deploy to production stage
runs-on: ubuntu-latest
needs: [production-postgres-migration]
environment:
name: Production
url: https://app.infisical.com
steps:
- name: ☁️ Checkout source
uses: actions/checkout@v3
- name: Configure AWS Credentials - name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4 uses: aws-actions/configure-aws-credentials@v4
with: with: