Giter Club home page Giter Club logo

azure-container-app's Introduction

azure-container-app

az login
az upgrade
az extension add --name containerapp --upgrade

# Register the Microsoft.App and Microsoft.OperationalInsights namespaces in your Azure subscription if you haven't
az provider register --namespace Microsoft.App
az provider register --namespace Microsoft.OperationalInsights
source .env

az group create --name $RESOURCE_GROUP --location $LOCATION --subscription $SUBSCRIPTION_ID

# az containerapp create --name $CONTAINER_APP_NAME --resource-group $RESOURCE_GROUP --location $LOCATION --image $IMAGE --cpu 1 --memory 1 --port 80 --environment-variables $ENVIRONMENT_VARIABLES

# deploy app1
az containerapp up \
  --name my-container-app \
  --resource-group $RESOURCE_GROUP \
  --location $LOCATION \
  --subscription $SUBSCRIPTION_ID \
  --environment 'my-container-apps' \
  --image mcr.microsoft.com/k8se/quickstart:latest \
  --target-port 80 \
  --ingress external \
  --query properties.configuration.ingress.fqdn

# deploy app2
az containerapp up \
  --name my-container-app2 \
  --resource-group $RESOURCE_GROUP \
  --location $LOCATION \
  --subscription $SUBSCRIPTION_ID \
  --environment 'my-container-apps' \
  --image index.docker.io/raychung/azure-docker-fastapi-nginx \
  --target-port 80 \
  --ingress external \
  --query properties.configuration.ingress.fqdn


# deploy app3
az containerapp up \
  --name my-container-app3 \
  --resource-group $RESOURCE_GROUP \
  --location $LOCATION \
  --subscription $SUBSCRIPTION_ID \
  --environment 'my-container-apps' \
  --image index.docker.io/raychung/recommendation-engine-serving-container \
  --target-port 80 \
  --ingress external \
  --query properties.configuration.ingress.fqdn
az containerapp delete -y --name my-container-app2 --resource-group $RESOURCE_GROUP --subscription $SUBSCRIPTION_ID
az group delete --name my-container-apps

AKS

# Create AKS cluster
az aks create --resource-group $RESOURCE_GROUP --name my-aks --subscription $SUBSCRIPTION_ID --node-count 3 --enable-addons monitoring --generate-ssh-keys

# Configure kubectl to use the credentials from the AKS cluster
az aks get-credentials --resource-group $RESOURCE_GROUP --subscription $SUBSCRIPTION_ID --name my-aks

References

Learn how to deploy a serverless ML inference using FastAPI, AWS Lambda, and API Gateway: https://aws.plainenglish.io/deploy-a-serverless-ml-inference-using-fastapi-aws-lambda-and-api-gateway-32b0b9a40236

azure-container-app's People

Contributors

ray-chunkit-chung avatar

Watchers

 avatar

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.