Merge pull request #19 from vishnumohanan404/dev #14
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: deploy-manifests | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- "infra/**" | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Authenticate with Google Cloud | |
uses: 'google-github-actions/auth@v2' | |
with: | |
credentials_json: ${{ secrets.GKE_SA_KEY }} | |
- name: Set up Google Cloud SDK | |
uses: google-github-actions/setup-gcloud@v2 | |
with: | |
version: "latest" | |
project_id: ${{ secrets.GKE_PROJECT_ID }} | |
- name: Install gke-gcloud-auth-plugin | |
run: gcloud components install gke-gcloud-auth-plugin | |
- name: Configure kubectl | |
run: gcloud container clusters get-credentials ${{secrets.GKE_CLUSTER_NAME}} --region=${{secrets.GKE_REGION}} --project=${{ secrets.GKE_PROJECT_ID }} | |
- run: kubectl apply -f infra/k8s && kubectl apply -f infra/k8s-prod |