From a1b0194ec9de09900af79d8bc301ceee4210f1c8 Mon Sep 17 00:00:00 2001 From: Vitor Hideyoshi Date: Sat, 1 Nov 2025 22:06:55 -0300 Subject: [PATCH] feat: better environment configuration --- .github/workflows/deploy.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index b61a4e6..ef0ea18 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -83,7 +83,9 @@ jobs: needs: [docker] runs-on: ubuntu-latest if: github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && github.ref == 'refs/heads/main') - environment: ${{ github.ref_name == 'main' && 'production' || 'dev' }} + environment: + name: ${{ github.ref_name == 'main' && 'production' || 'dev' }} + url: https://${{ vars.KUBE_DOMAIN }} env: # Kubernetes Specific KUBE_NAMESPACE: ${{ vars.KUBE_NAMESPACE }} @@ -111,6 +113,7 @@ jobs: TAG="${{ github.event.inputs.tag || 'latest' }}" echo "Deploying image: ${IMAGE_BASE}:${TAG} to Kubernetes Namespace: ${KUBE_NAMESPACE}" + kubectl config use-context --current --namespace=${KUBE_NAMESPACE} # Apply any other configuration changes if needed envsubst < .k8s/config.yml | kubectl apply -f -