Firewall Rule Args
data class FirewallRuleArgs(val endIpAddress: Output<String>? = null, val name: Output<String>? = null, val resourceGroupName: Output<String>? = null, val serverName: Output<String>? = null, val startIpAddress: Output<String>? = null) : ConvertibleToJava<FirewallRuleArgs>
Manages a Firewall Rule for a MariaDB Server
Example Usage
Single IP Address)
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = new azure.mariadb.FirewallRule("example", {
name: "test-rule",
resourceGroupName: "test-rg",
serverName: "test-server",
startIpAddress: "40.112.8.12",
endIpAddress: "40.112.8.12",
});
Content copied to clipboard
import pulumi
import pulumi_azure as azure
example = azure.mariadb.FirewallRule("example",
name="test-rule",
resource_group_name="test-rg",
server_name="test-server",
start_ip_address="40.112.8.12",
end_ip_address="40.112.8.12")
Content copied to clipboard
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = new Azure.MariaDB.FirewallRule("example", new()
{
Name = "test-rule",
ResourceGroupName = "test-rg",
ServerName = "test-server",
StartIpAddress = "40.112.8.12",
EndIpAddress = "40.112.8.12",
});
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/mariadb"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := mariadb.NewFirewallRule(ctx, "example", &mariadb.FirewallRuleArgs{
Name: pulumi.String("test-rule"),
ResourceGroupName: pulumi.String("test-rg"),
ServerName: pulumi.String("test-server"),
StartIpAddress: pulumi.String("40.112.8.12"),
EndIpAddress: pulumi.String("40.112.8.12"),
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.mariadb.FirewallRule;
import com.pulumi.azure.mariadb.FirewallRuleArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new FirewallRule("example", FirewallRuleArgs.builder()
.name("test-rule")
.resourceGroupName("test-rg")
.serverName("test-server")
.startIpAddress("40.112.8.12")
.endIpAddress("40.112.8.12")
.build());
}
}
Content copied to clipboard
resources:
example:
type: azure:mariadb:FirewallRule
properties:
name: test-rule
resourceGroupName: test-rg
serverName: test-server
startIpAddress: 40.112.8.12
endIpAddress: 40.112.8.12
Content copied to clipboard
IP Range)
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = new azure.mariadb.FirewallRule("example", {
name: "test-rule",
resourceGroupName: "test-rg",
serverName: "test-server",
startIpAddress: "40.112.0.0",
endIpAddress: "40.112.255.255",
});
Content copied to clipboard
import pulumi
import pulumi_azure as azure
example = azure.mariadb.FirewallRule("example",
name="test-rule",
resource_group_name="test-rg",
server_name="test-server",
start_ip_address="40.112.0.0",
end_ip_address="40.112.255.255")
Content copied to clipboard
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = new Azure.MariaDB.FirewallRule("example", new()
{
Name = "test-rule",
ResourceGroupName = "test-rg",
ServerName = "test-server",
StartIpAddress = "40.112.0.0",
EndIpAddress = "40.112.255.255",
});
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/mariadb"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := mariadb.NewFirewallRule(ctx, "example", &mariadb.FirewallRuleArgs{
Name: pulumi.String("test-rule"),
ResourceGroupName: pulumi.String("test-rg"),
ServerName: pulumi.String("test-server"),
StartIpAddress: pulumi.String("40.112.0.0"),
EndIpAddress: pulumi.String("40.112.255.255"),
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.mariadb.FirewallRule;
import com.pulumi.azure.mariadb.FirewallRuleArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new FirewallRule("example", FirewallRuleArgs.builder()
.name("test-rule")
.resourceGroupName("test-rg")
.serverName("test-server")
.startIpAddress("40.112.0.0")
.endIpAddress("40.112.255.255")
.build());
}
}
Content copied to clipboard
resources:
example:
type: azure:mariadb:FirewallRule
properties:
name: test-rule
resourceGroupName: test-rg
serverName: test-server
startIpAddress: 40.112.0.0
endIpAddress: 40.112.255.255
Content copied to clipboard
Import
MariaDB Firewall rules can be imported using the resource id
, e.g.
$ pulumi import azure:mariadb/firewallRule:FirewallRule rule1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.DBforMariaDB/servers/server1/firewallRules/rule1
Content copied to clipboard
Constructors
Properties
Link copied to clipboard
Specifies the End IP Address associated with this Firewall Rule.
Link copied to clipboard
The name of the resource group in which the MariaDB Server exists. Changing this forces a new resource to be created.
Link copied to clipboard
Specifies the name of the MariaDB Server. Changing this forces a new resource to be created.
Link copied to clipboard
Specifies the Start IP Address associated with this Firewall Rule.