Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
AzureSqlPasS - Add Firewall Rule
# Init variables
$resourceGroupName = "ResourceGroupName"
$serverName = "ServerName"
$firewallRuleName = "ServerFirewallRuleName"
# Add firewall rules
$newAzureRmSqlServerFirewallRuleSplat = @{
ServerName = $serverName
StartIpAddress = "IpAddressStart"
EndIpAddress = "IpAddressEnd"
ResourceGroupName = $resourceGroupName
FirewallRuleName = $firewallRuleName
$null = New-AzureRmSqlServerFirewallRule @newAzureRmSqlServerFirewallRuleSplat
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.