From 908f8ae502366ab184a35e3e2a97c22baa5b3dc7 Mon Sep 17 00:00:00 2001 From: n-y-kim Date: Thu, 14 Mar 2024 23:58:47 +0900 Subject: [PATCH] Update action workflow --- .github/workflows/app.yaml | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/.github/workflows/app.yaml b/.github/workflows/app.yaml index 02917d6f..8702e734 100644 --- a/.github/workflows/app.yaml +++ b/.github/workflows/app.yaml @@ -1,5 +1,6 @@ -name: frontend_build_deploy +name: Build Dockerfile & Push to ACR & Deploy to AKS on: + workflow_dispatch: push: paths: - "app/**" @@ -14,11 +15,11 @@ jobs: id: build-push-acr uses: azure/acr-build@v1 with: - service_principal: ${{ secrets.service_principal }} - service_principal_password: ${{ secrets.service_principal_password }} - tenant: ${{ secrets.tenant }} - registry: ${{ secrets.registry }} - repository: ${{ secrets.repository }} + service_principal: ${{ secrets.SERVICE_PRINCIPAL }} + service_principal_password: ${{ secrets.SERVICE_PRINCIPAL_PASSWORD }} + tenant: ${{ secrets.TENANT }} + registry: ${{ secrets.REGISTRY }} + repository: ${{ secrets.REPOSITORY }} image: chatbot-app folder: app branch: main @@ -39,8 +40,8 @@ jobs: id: set-context uses: azure/aks-set-context@v3 with: - resource-group: '${{ secrets.resource_group }}' - cluster-name: '${{ secrets.cluster_name }}' + resource-group: '${{ secrets.RESOURCE_GROUP }}' + cluster-name: '${{ secrets.CLUSTER_NAME }}' - name: Setup kubectl id: install-kubectl @@ -53,5 +54,5 @@ jobs: namespace: 'default' manifests: | manifest/app.yaml - images: '${{ secrets.registry }}.azurecr.io/${{ secrets.repository }}/chatbot-app:${{ github.sha }}' + images: '${{ secrets.REGISTRY }}.azurecr.io/${{ secrets.REPOSITORY }}/chatbot-app:${{ github.sha }}' pull-images: false \ No newline at end of file