DEV Community ๐Ÿ‘ฉโ€๐Ÿ’ป๐Ÿ‘จโ€๐Ÿ’ป

DEV Community ๐Ÿ‘ฉโ€๐Ÿ’ป๐Ÿ‘จโ€๐Ÿ’ป is a community of 963,503 amazing developers

We're a place where coders share, stay up-to-date and grow their careers.

Create account Log in
Cover image for Deploying Grafana Image to Azure Container Registry Using Azure CLI
Suryabhan Singh Vaghela
Suryabhan Singh Vaghela

Posted on • Updated on

Deploying Grafana Image to Azure Container Registry Using Azure CLI

Goal :

  • Create Grafana Image to Azure Container Registry using Azure CLI

Result

  • Private Container Image rather than Public Docker Hub Image.

Script

$ResourceGroupName  = "suryarg"
$LocationName       = "eastus2"
$ACRName            = "suryacr"
$ACRUrl             = "$ACRName.azurecr.io"

#Create a resource group
az group create --name $ResourceGroupName --location $LocationName

#Create a container registry
az acr create --resource-group $ResourceGroupName --name $ACRName --sku Basic --admin-enabled true


#Log in to Azure Container Registry
az acr login --name $ACRName


#First Pull latest Grafana Image from DockerHub
docker pull grafana/grafana:latest

#Then Push into Azure Container Registry
docker tag grafana/grafana:latest $ACRUrl/grafana:SuryaLatest
docker push $ACRUrl/grafana:SuryaLatest
Enter fullscreen mode Exit fullscreen mode

Result

1

2

Top comments (1)

Collapse
 
sulianeal profile image
Info Comment hidden by post author - thread only accessible via permalink
SuliaNeal

The Azure Container Apps service enables me to run microservices and containerized applications on a serverless platform. With Container Apps, I enjoy the benefits of running containers . Spells to make someone go away

Some comments have been hidden by the post's author - find out more

Update Your DEV Experience Level:

Settings

Go to your customization settings to nudge your home feed to show content more relevant to your developer experience level. ๐Ÿ›