Skip to content

Update k8-service.yaml #10

Update k8-service.yaml

Update k8-service.yaml #10

Workflow file for this run

name: Deploy to AKS
on:
push:
branches:
- master # Set the branch you want to trigger the deployment on
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Kubernetes CLI
uses: azure/setup-kubectl@v1
with:
version: 'v1.29.7' # Corrected to match the Kubernetes versioning
- name: Create .kube directory
run: mkdir -p $HOME/.kube
- name: Set up Kubeconfig
run: |
echo "${{ secrets.KUBE_CONFIG_DATA }}" | base64 -d > $HOME/.kube/config
- name: Deploy manifests
run: |
kubectl apply -f k8-manifest/k8-deployment.yaml
kubectl apply -f k8-manifest/k8-service.yaml
kubectl apply -f k8-manifest/metrics-server.yaml
kubectl apply -f k8-manifest/tetris-hpa.yaml
- name: Verify Deployment
run: |
kubectl rollout status deployment/tetris-deployment
kubectl get pods