-
Notifications
You must be signed in to change notification settings - Fork 4.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for Azure Bastion Developer SKU #23808
Comments
Thanks for raising this issue. After checked, seems azure-rest-api-specs hasn't supported this new feature yet. Once it's supported, we will take another look. Thanks. |
Hi Neil, from what I can see now is that the Developer SKU is now part of the 2023-06-01 spec. Would be good to have this integrated into the Terraform Provider soon as Bastion is used by many developers. |
@rcskosir @mybayern1974 @neil-yechenwei Sorry for bumping this, was hoping this had already had some attention... |
Sorry for late response. Though this new SKU is released to 2023-06-01 spec but this feature is still in preview. See more details from https://learn.microsoft.com/en-us/azure/bastion/quickstart-developer-sku. |
Hey, as it's been a few months since this post, was wondering if there's been any progress or update that can be made for this? |
@tfstateuk - I did see that there was an announcement on internet that Bastion Developer had been GA'd (https://azure.microsoft.com/en-us/updates/general-availability-azure-bastion-developer-sku/) but it seems that the announcement has been pulled back. Meanwhile I've gotten it to work and be deployable from Terraform by using "azurerm_resource_group_template_deployment" in conjunction with the ARM template that the portal spits out. This seems to work just as well. Example: resource "azurerm_resource_group_template_deployment" "BAST-EU-NE-TEST" {
name = "BAST-EU-NE-TEST"
resource_group_name = azurerm_resource_group.RG-EU-LAB-NE-BASTION.name
deployment_mode = "Incremental"
parameters_content = jsonencode({
"location": {
"value": "northeurope"
},
"resourceGroup": {
"value": "RG-EU-LAB-NE-BASTION"
},
"bastionHostName": {
"value": "Bastion01"
},
"bastionHostSku": {
"value": "Developer"
},
"vnetId": {
"value": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/RG-EU-LAB-NE-TEST/providers/Microsoft.Network/virtualNetworks/VNET"
}
})
template_content = file("./templates/bastion.json")
} The referenced json can be found here: {
"$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"location": {
"type": "String"
},
"resourceGroup": {
"type": "String"
},
"bastionHostName": {
"type": "String"
},
"vnetId": {
"type": "String"
},
"bastionHostSku": {
"type": "String"
}
},
"resources": [
{
"apiVersion": "2022-09-01",
"type": "Microsoft.Network/bastionHosts",
"name": "[parameters('bastionHostName')]",
"sku": {
"name": "[parameters('bastionHostSku')]"
},
"location": "[parameters('location')]",
"dependsOn": [],
"properties": {
"virtualNetwork": {
"id": "[parameters('vnetId')]"
}
},
"tags": {}
}
]
}
This works for me to deploy Azure Bastion in the Developer SKU until we can get native support sorted. Hope this helps you and perhaps some of the others that might want to use it this way. |
Thank you, I'll give this a go! |
It looks like the API has been updated, the AzAPI provider references support for the Developer sku now - https://learn.microsoft.com/en-us/azure/templates/microsoft.network/bastionhosts?pivots=deployment-language-terraform#sku-2:~:text=string-,Sku,-Expand%20table |
I'm going to give it a test now and report back..I have it commented out in dev , so will report back |
sadly no success, maybe the API hasn't quite been updated just yet..however the arm template method referenced above is working fine |
So though this is Closed and classed as completed, still getting the error │ Error: expected sku to be one of ["Basic" "Standard"], got Developer What are the next steps with getting this available now the API is updated? |
@tfstateuk this will be available v3.106.0 of the provider which will be released at the end of this week. |
So the good news 3.106.0 is out, and the developer SKU is working as expected :) Here's the expected code for those who are looking for it.. resource "azurerm_bastion_host" "bastionhost" { |
Is there an existing issue for this?
Community Note
Description
Azure Bastion Developer SKU is in Public Preview:
https://azure.microsoft.com/de-de/updates/azure-bastion-developer-public-preview/
Current Error:
New or Affected Resource(s)/Data Source(s)
azurerm_bastion_host
Potential Terraform Configuration
References
No response
The text was updated successfully, but these errors were encountered: