Allow create or not ACR when creating k8s
This commit is contained in:
parent
11a5293fa0
commit
8c9498c7a1
@ -3,16 +3,19 @@
|
|||||||
[parameter(Mandatory=$true)][string]$location,
|
[parameter(Mandatory=$true)][string]$location,
|
||||||
[parameter(Mandatory=$true)][string]$registryName,
|
[parameter(Mandatory=$true)][string]$registryName,
|
||||||
[parameter(Mandatory=$true)][string]$orchestratorName,
|
[parameter(Mandatory=$true)][string]$orchestratorName,
|
||||||
[parameter(Mandatory=$true)][string]$dnsName
|
[parameter(Mandatory=$true)][string]$dnsName,
|
||||||
|
[parameter(Mandatory=$true)][string]$createAcr=$true
|
||||||
)
|
)
|
||||||
|
|
||||||
# Create resource group
|
# Create resource group
|
||||||
Write-Host "Creating resource group..." -ForegroundColor Yellow
|
Write-Host "Creating resource group..." -ForegroundColor Yellow
|
||||||
az group create --name=$resourceGroupName --location=$location
|
az group create --name=$resourceGroupName --location=$location
|
||||||
|
|
||||||
# Create Azure Container Registry
|
if ($createAcr) {
|
||||||
Write-Host "Creating Azure Container Registry..." -ForegroundColor Yellow
|
# Create Azure Container Registry
|
||||||
az acr create -n $registryName -g $resourceGroupName -l $location --admin-enabled true --sku Basic
|
Write-Host "Creating Azure Container Registry..." -ForegroundColor Yellow
|
||||||
|
az acr create -n $registryName -g $resourceGroupName -l $location --admin-enabled true --sku Basic
|
||||||
|
}
|
||||||
|
|
||||||
# Create kubernetes orchestrator
|
# Create kubernetes orchestrator
|
||||||
Write-Host "Creating kubernetes orchestrator..." -ForegroundColor Yellow
|
Write-Host "Creating kubernetes orchestrator..." -ForegroundColor Yellow
|
||||||
|
Loading…
x
Reference in New Issue
Block a user