strType=AzureBlob strType=AzureFiles az webapp config storage-account add \ --access-key $strAccessKey --account-name $strAccountName --custom-id $strCustomId --share-name $strContainerName --storage-type $strType --mount-path $mountPath
az group create --name mygroup --location japanwest
az acr create --name レジストリ名 --resource-group mygroup --sku standard --admin-enabled true
Dockerfileからイメージを作成
az acr build --file Dockerfile --registry レジストリ名 --image イメージ名 .
docker-compose.yml からWebアプリを作成
az webapp create --resource-group myResourceGroup --plan myAppServicePlan --name アプリケーション名 --multicontainer-config-type compose --multicontainer-config-file docker-compose.yml
docker-compose.yml
version: "3" services: grafana: image: イメージ名:タグ名 ports: - "3000:3000" environment: - GF_SERVER_ROOT_URL=http://localhost:3000 - GF_SECURITY_ADMIN_PASSWORD=admin
AzureFiles では SQLite の共有は出来ない模様。
https://github.com/kubernetes/kubernetes/issues/59755
AzureFileを使用してこの問題を解決することはできませんでした。 そこで、回避策として、AzureDiskを使用してGrafanaとPrometheusの永続的なボリュームバックエンドとしてボリュームを作成しました。 リファレンス: https://docs.microsoft.com/en-us/azure/aks/azure-disk-volume