Skip to content

5 Deploy Web App

5 Deploy Web App #5

Workflow file for this run

name: 5 Deploy Web App
on: [workflow_dispatch]
env:
CLUSTER_NAME: AKSClsuter-Demo
AZURE_RG: oa-poc-rg
NAMESPACE: appconfig
IMAGE_NAME: oawebappconfig
AZURE_CONTAINER_REGISTRY: ${{ secrets.CONTAINER_REGISTRY }}
KUSTOMIZE_PATH: './yaml_files/'
TAG: 5141
jobs:
deploy-webapp:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
# Set the target AKS cluster.
- uses: Azure/aks-set-context@v1
with:
creds: '${{ secrets.AZURE_CREDENTIALS }}'
cluster-name: ${{ env.CLUSTER_NAME }}
resource-group: ${{ env.AZURE_RG }}
# Runs Kustomize to create manifest files
- name: Bake deployment
uses: azure/k8s-bake@v2
with:
renderEngine: "kustomize"
kustomizationPath: ${{ env.KUSTOMIZE_PATH }}
kubectl-version: latest
id: bake
# Deploys application based on manifest files from previous step
- name: Deploy application
uses: Azure/k8s-deploy@v4
with:
action: deploy
manifests: ${{ steps.bake.outputs.manifestsBundle }}
images: |
${{ env.AZURE_CONTAINER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.TAG }}