Git Product home page Git Product logo

deploying-an-asp.net-core-3.0-web-api-on-aks's Introduction

Docker & Kubernetes Notes

Containirize dotnet core web Api using Docker, push to Azure Container Registry and deploy to Kubernetes cluster in AKS

Pre-requisites

  1. Install docker desktop on windows machine

  2. Install Azure CLI on windows machine

  3. Create Service Principal in Azure AD

  4. Create Azure Container Registry

  5. Configure RBAC in Azure Container Registry (Acrpull) for the Service Principal

Service Principal

  1. az login

  2. az account show

  3. az ad sp create-for-rbac --skip-assignment

Azure Container Registry - Push Docker images

  1. az acr login --name retailcontainerregistry

  2. docker images

  3. docker tag orderservice:v2 retailcontainerregistry.azurecr.io/orderservice:v2

  4. docker images

  5. docker push retailcontainerregistry.azurecr.io/orderservice:v2

Azure Kubernetes Service - Create Kubernetes Cluster & run containers

  1. az aks get-credentials --resource-group rg-cosmos --name retailkubernetescluster

  2. kubectl get nodes

  3. kubectl apply -f .\Deployment.yml

  4. kubectl get deployment

  5. kubectl get pods

  6. kubectl apply -f .\Service.yml

  7. kubectl get services

deploying-an-asp.net-core-3.0-web-api-on-aks's People

Contributors

aditmodi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

deploying-an-asp.net-core-3.0-web-api-on-aks's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.