azure-native.sql.ServerDnsAlias

Explore with Pulumi AI

A server DNS alias. API Version: 2020-11-01-preview.

Example Usage

Create server DNS alias

using System.Collections.Generic;
using Pulumi;
using AzureNative = Pulumi.AzureNative;

return await Deployment.RunAsync(() => 
{
    var serverDnsAlias = new AzureNative.Sql.ServerDnsAlias("serverDnsAlias", new()
    {
        DnsAliasName = "dns-alias-name-1",
        ResourceGroupName = "Default",
        ServerName = "dns-alias-server",
    });

});
package main

import (
	sql "github.com/pulumi/pulumi-azure-native/sdk/go/azure/sql"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := sql.NewServerDnsAlias(ctx, "serverDnsAlias", &sql.ServerDnsAliasArgs{
			DnsAliasName:      pulumi.String("dns-alias-name-1"),
			ResourceGroupName: pulumi.String("Default"),
			ServerName:        pulumi.String("dns-alias-server"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.sql.ServerDnsAlias;
import com.pulumi.azurenative.sql.ServerDnsAliasArgs;
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 serverDnsAlias = new ServerDnsAlias("serverDnsAlias", ServerDnsAliasArgs.builder()        
            .dnsAliasName("dns-alias-name-1")
            .resourceGroupName("Default")
            .serverName("dns-alias-server")
            .build());

    }
}
import pulumi
import pulumi_azure_native as azure_native

server_dns_alias = azure_native.sql.ServerDnsAlias("serverDnsAlias",
    dns_alias_name="dns-alias-name-1",
    resource_group_name="Default",
    server_name="dns-alias-server")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";

const serverDnsAlias = new azure_native.sql.ServerDnsAlias("serverDnsAlias", {
    dnsAliasName: "dns-alias-name-1",
    resourceGroupName: "Default",
    serverName: "dns-alias-server",
});
resources:
  serverDnsAlias:
    type: azure-native:sql:ServerDnsAlias
    properties:
      dnsAliasName: dns-alias-name-1
      resourceGroupName: Default
      serverName: dns-alias-server

Create ServerDnsAlias Resource

new ServerDnsAlias(name: string, args: ServerDnsAliasArgs, opts?: CustomResourceOptions);
@overload
def ServerDnsAlias(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   dns_alias_name: Optional[str] = None,
                   resource_group_name: Optional[str] = None,
                   server_name: Optional[str] = None)
@overload
def ServerDnsAlias(resource_name: str,
                   args: ServerDnsAliasArgs,
                   opts: Optional[ResourceOptions] = None)
func NewServerDnsAlias(ctx *Context, name string, args ServerDnsAliasArgs, opts ...ResourceOption) (*ServerDnsAlias, error)
public ServerDnsAlias(string name, ServerDnsAliasArgs args, CustomResourceOptions? opts = null)
public ServerDnsAlias(String name, ServerDnsAliasArgs args)
public ServerDnsAlias(String name, ServerDnsAliasArgs args, CustomResourceOptions options)
type: azure-native:sql:ServerDnsAlias
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args ServerDnsAliasArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args ServerDnsAliasArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args ServerDnsAliasArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args ServerDnsAliasArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args ServerDnsAliasArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

ServerDnsAlias Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The ServerDnsAlias resource accepts the following input properties:

ResourceGroupName string

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

ServerName string

The name of the server that the alias is pointing to.

DnsAliasName string

The name of the server dns alias.

ResourceGroupName string

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

ServerName string

The name of the server that the alias is pointing to.

DnsAliasName string

The name of the server dns alias.

resourceGroupName String

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

serverName String

The name of the server that the alias is pointing to.

dnsAliasName String

The name of the server dns alias.

resourceGroupName string

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

serverName string

The name of the server that the alias is pointing to.

dnsAliasName string

The name of the server dns alias.

resource_group_name str

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

server_name str

The name of the server that the alias is pointing to.

dns_alias_name str

The name of the server dns alias.

resourceGroupName String

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

serverName String

The name of the server that the alias is pointing to.

dnsAliasName String

The name of the server dns alias.

Outputs

All input properties are implicitly available as output properties. Additionally, the ServerDnsAlias resource produces the following output properties:

AzureDnsRecord string

The fully qualified DNS record for alias

Id string

The provider-assigned unique ID for this managed resource.

Name string

Resource name.

Type string

Resource type.

AzureDnsRecord string

The fully qualified DNS record for alias

Id string

The provider-assigned unique ID for this managed resource.

Name string

Resource name.

Type string

Resource type.

azureDnsRecord String

The fully qualified DNS record for alias

id String

The provider-assigned unique ID for this managed resource.

name String

Resource name.

type String

Resource type.

azureDnsRecord string

The fully qualified DNS record for alias

id string

The provider-assigned unique ID for this managed resource.

name string

Resource name.

type string

Resource type.

azure_dns_record str

The fully qualified DNS record for alias

id str

The provider-assigned unique ID for this managed resource.

name str

Resource name.

type str

Resource type.

azureDnsRecord String

The fully qualified DNS record for alias

id String

The provider-assigned unique ID for this managed resource.

name String

Resource name.

type String

Resource type.

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:sql:ServerDnsAlias dns-alias-name-1 /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default/providers/Microsoft.Sql/servers/dns-alias-server/dnsAliases/dns-alias-name-1 

Package Details

Repository
Azure Native pulumi/pulumi-azure-native
License
Apache-2.0