From 13fb949282093ee7870660a67aa99f291e2fd245 Mon Sep 17 00:00:00 2001 From: hkirat Date: Fri, 29 Nov 2024 03:21:35 +0530 Subject: [PATCH] Added ci --- .github/workflows/cd_prod.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/cd_prod.yml b/.github/workflows/cd_prod.yml index 7d2b2c100..a6ab18376 100644 --- a/.github/workflows/cd_prod.yml +++ b/.github/workflows/cd_prod.yml @@ -19,6 +19,18 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 + # Set up Kubernetes CLI and configure access + - name: Set up kubectl + uses: azure/setup-kubectl@v1 + with: + kubeconfig: ${{ secrets.KUBE_POSTGRES_CONFIG }} + + # Proxy the database (use kubectl port-forward or other mechanisms) + - name: Proxy Database using Kubernetes + run: | + kubectl port-forward svc/postgres 5432:5432 -n postgres + sleep 5 + - name: Build and push uses: docker/build-push-action@v4 with: