https://pulumi.com logo
#azure
Title
# azure
b

breezy-animal-52081

02/15/2021, 11:43 AM
Hey, does anyone know how to create a Serverless tier Azure SQL Database, any advice would be appreciated? I am trying to create an Azure SQL database with Serverless billing, however whilst I can set the 
Pulumi.Azure.Sql.DatabaseArgs.Edition
 property to "GeneralPurpose" I can't see how to set ComputeModel to serverless. Here is the equivalent Azure command line call:
New-AzSqlDatabase -ResourceGroupName $resourceGroupName -ServerName $serverName -DatabaseName $databaseName  -ComputeModel Serverless -Edition GeneralPurpose -ComputeGeneration Gen5  -MinVcore 0.5 -MaxVcore 2 -AutoPauseDelayInMinutes 720
 as per this page: https://docs.microsoft.com/en-gb/azure/azure-sql/database/serverless-tier-overview#use-powershell Thanks!
t

tall-librarian-49374

02/15/2021, 11:48 AM
If you were to use Azure NextGen, it would be
Copy code
sku: {
  name: "GP_S_Gen5",
  tier: "GeneralPurpose",
  family: "Gen5",
  capacity: 1
},
I don’t know how this translates to the classic Azure provider.
b

breezy-animal-52081

02/15/2021, 5:25 PM
A great thank you, does that specify serverless, I think by default GeneralPurpose is "Provisioned"?
t

tall-librarian-49374

02/15/2021, 6:03 PM
I guess
GP_S_Gen5
is the magic value. I took it from ARM templates.
3 Views