1. Packages
  2. Azure Native
  3. API Docs
  4. sql
  5. ManagedInstanceAdministrator
This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
Azure Native v2.47.1 published on Monday, Jun 24, 2024 by Pulumi

azure-native.sql.ManagedInstanceAdministrator

Explore with Pulumi AI

azure-native logo
This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
Azure Native v2.47.1 published on Monday, Jun 24, 2024 by Pulumi

    An Azure SQL managed instance administrator. Azure REST API version: 2021-11-01. Prior API version in Azure Native 1.x: 2020-11-01-preview.

    Other available API versions: 2022-11-01-preview, 2023-02-01-preview, 2023-05-01-preview, 2023-08-01-preview.

    Example Usage

    Create administrator of managed instance

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureNative = Pulumi.AzureNative;
    
    return await Deployment.RunAsync(() => 
    {
        var managedInstanceAdministrator = new AzureNative.Sql.ManagedInstanceAdministrator("managedInstanceAdministrator", new()
        {
            AdministratorName = "ActiveDirectory",
            AdministratorType = AzureNative.Sql.ManagedInstanceAdministratorType.ActiveDirectory,
            Login = "bob@contoso.com",
            ManagedInstanceName = "managedInstance",
            ResourceGroupName = "Default-SQL-SouthEastAsia",
            Sid = "44444444-3333-2222-1111-000000000000",
            TenantId = "55555555-4444-3333-2222-111111111111",
        });
    
    });
    
    package main
    
    import (
    	sql "github.com/pulumi/pulumi-azure-native-sdk/sql/v2"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := sql.NewManagedInstanceAdministrator(ctx, "managedInstanceAdministrator", &sql.ManagedInstanceAdministratorArgs{
    			AdministratorName:   pulumi.String("ActiveDirectory"),
    			AdministratorType:   pulumi.String(sql.ManagedInstanceAdministratorTypeActiveDirectory),
    			Login:               pulumi.String("bob@contoso.com"),
    			ManagedInstanceName: pulumi.String("managedInstance"),
    			ResourceGroupName:   pulumi.String("Default-SQL-SouthEastAsia"),
    			Sid:                 pulumi.String("44444444-3333-2222-1111-000000000000"),
    			TenantId:            pulumi.String("55555555-4444-3333-2222-111111111111"),
    		})
    		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.ManagedInstanceAdministrator;
    import com.pulumi.azurenative.sql.ManagedInstanceAdministratorArgs;
    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 managedInstanceAdministrator = new ManagedInstanceAdministrator("managedInstanceAdministrator", ManagedInstanceAdministratorArgs.builder()
                .administratorName("ActiveDirectory")
                .administratorType("ActiveDirectory")
                .login("bob@contoso.com")
                .managedInstanceName("managedInstance")
                .resourceGroupName("Default-SQL-SouthEastAsia")
                .sid("44444444-3333-2222-1111-000000000000")
                .tenantId("55555555-4444-3333-2222-111111111111")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_azure_native as azure_native
    
    managed_instance_administrator = azure_native.sql.ManagedInstanceAdministrator("managedInstanceAdministrator",
        administrator_name="ActiveDirectory",
        administrator_type=azure_native.sql.ManagedInstanceAdministratorType.ACTIVE_DIRECTORY,
        login="bob@contoso.com",
        managed_instance_name="managedInstance",
        resource_group_name="Default-SQL-SouthEastAsia",
        sid="44444444-3333-2222-1111-000000000000",
        tenant_id="55555555-4444-3333-2222-111111111111")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure_native from "@pulumi/azure-native";
    
    const managedInstanceAdministrator = new azure_native.sql.ManagedInstanceAdministrator("managedInstanceAdministrator", {
        administratorName: "ActiveDirectory",
        administratorType: azure_native.sql.ManagedInstanceAdministratorType.ActiveDirectory,
        login: "bob@contoso.com",
        managedInstanceName: "managedInstance",
        resourceGroupName: "Default-SQL-SouthEastAsia",
        sid: "44444444-3333-2222-1111-000000000000",
        tenantId: "55555555-4444-3333-2222-111111111111",
    });
    
    resources:
      managedInstanceAdministrator:
        type: azure-native:sql:ManagedInstanceAdministrator
        properties:
          administratorName: ActiveDirectory
          administratorType: ActiveDirectory
          login: bob@contoso.com
          managedInstanceName: managedInstance
          resourceGroupName: Default-SQL-SouthEastAsia
          sid: 44444444-3333-2222-1111-000000000000
          tenantId: 55555555-4444-3333-2222-111111111111
    

    Update administrator of managed instance

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureNative = Pulumi.AzureNative;
    
    return await Deployment.RunAsync(() => 
    {
        var managedInstanceAdministrator = new AzureNative.Sql.ManagedInstanceAdministrator("managedInstanceAdministrator", new()
        {
            AdministratorName = "ActiveDirectory",
            AdministratorType = AzureNative.Sql.ManagedInstanceAdministratorType.ActiveDirectory,
            Login = "bob@contoso.com",
            ManagedInstanceName = "managedInstance",
            ResourceGroupName = "Default-SQL-SouthEastAsia",
            Sid = "44444444-3333-2222-1111-000000000000",
            TenantId = "55555555-4444-3333-2222-111111111111",
        });
    
    });
    
    package main
    
    import (
    	sql "github.com/pulumi/pulumi-azure-native-sdk/sql/v2"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := sql.NewManagedInstanceAdministrator(ctx, "managedInstanceAdministrator", &sql.ManagedInstanceAdministratorArgs{
    			AdministratorName:   pulumi.String("ActiveDirectory"),
    			AdministratorType:   pulumi.String(sql.ManagedInstanceAdministratorTypeActiveDirectory),
    			Login:               pulumi.String("bob@contoso.com"),
    			ManagedInstanceName: pulumi.String("managedInstance"),
    			ResourceGroupName:   pulumi.String("Default-SQL-SouthEastAsia"),
    			Sid:                 pulumi.String("44444444-3333-2222-1111-000000000000"),
    			TenantId:            pulumi.String("55555555-4444-3333-2222-111111111111"),
    		})
    		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.ManagedInstanceAdministrator;
    import com.pulumi.azurenative.sql.ManagedInstanceAdministratorArgs;
    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 managedInstanceAdministrator = new ManagedInstanceAdministrator("managedInstanceAdministrator", ManagedInstanceAdministratorArgs.builder()
                .administratorName("ActiveDirectory")
                .administratorType("ActiveDirectory")
                .login("bob@contoso.com")
                .managedInstanceName("managedInstance")
                .resourceGroupName("Default-SQL-SouthEastAsia")
                .sid("44444444-3333-2222-1111-000000000000")
                .tenantId("55555555-4444-3333-2222-111111111111")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_azure_native as azure_native
    
    managed_instance_administrator = azure_native.sql.ManagedInstanceAdministrator("managedInstanceAdministrator",
        administrator_name="ActiveDirectory",
        administrator_type=azure_native.sql.ManagedInstanceAdministratorType.ACTIVE_DIRECTORY,
        login="bob@contoso.com",
        managed_instance_name="managedInstance",
        resource_group_name="Default-SQL-SouthEastAsia",
        sid="44444444-3333-2222-1111-000000000000",
        tenant_id="55555555-4444-3333-2222-111111111111")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure_native from "@pulumi/azure-native";
    
    const managedInstanceAdministrator = new azure_native.sql.ManagedInstanceAdministrator("managedInstanceAdministrator", {
        administratorName: "ActiveDirectory",
        administratorType: azure_native.sql.ManagedInstanceAdministratorType.ActiveDirectory,
        login: "bob@contoso.com",
        managedInstanceName: "managedInstance",
        resourceGroupName: "Default-SQL-SouthEastAsia",
        sid: "44444444-3333-2222-1111-000000000000",
        tenantId: "55555555-4444-3333-2222-111111111111",
    });
    
    resources:
      managedInstanceAdministrator:
        type: azure-native:sql:ManagedInstanceAdministrator
        properties:
          administratorName: ActiveDirectory
          administratorType: ActiveDirectory
          login: bob@contoso.com
          managedInstanceName: managedInstance
          resourceGroupName: Default-SQL-SouthEastAsia
          sid: 44444444-3333-2222-1111-000000000000
          tenantId: 55555555-4444-3333-2222-111111111111
    

    Create ManagedInstanceAdministrator Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new ManagedInstanceAdministrator(name: string, args: ManagedInstanceAdministratorArgs, opts?: CustomResourceOptions);
    @overload
    def ManagedInstanceAdministrator(resource_name: str,
                                     args: ManagedInstanceAdministratorArgs,
                                     opts: Optional[ResourceOptions] = None)
    
    @overload
    def ManagedInstanceAdministrator(resource_name: str,
                                     opts: Optional[ResourceOptions] = None,
                                     administrator_type: Optional[Union[str, ManagedInstanceAdministratorType]] = None,
                                     login: Optional[str] = None,
                                     managed_instance_name: Optional[str] = None,
                                     resource_group_name: Optional[str] = None,
                                     sid: Optional[str] = None,
                                     administrator_name: Optional[str] = None,
                                     tenant_id: Optional[str] = None)
    func NewManagedInstanceAdministrator(ctx *Context, name string, args ManagedInstanceAdministratorArgs, opts ...ResourceOption) (*ManagedInstanceAdministrator, error)
    public ManagedInstanceAdministrator(string name, ManagedInstanceAdministratorArgs args, CustomResourceOptions? opts = null)
    public ManagedInstanceAdministrator(String name, ManagedInstanceAdministratorArgs args)
    public ManagedInstanceAdministrator(String name, ManagedInstanceAdministratorArgs args, CustomResourceOptions options)
    
    type: azure-native:sql:ManagedInstanceAdministrator
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args ManagedInstanceAdministratorArgs
    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 ManagedInstanceAdministratorArgs
    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 ManagedInstanceAdministratorArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ManagedInstanceAdministratorArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ManagedInstanceAdministratorArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var managedInstanceAdministratorResource = new AzureNative.Sql.ManagedInstanceAdministrator("managedInstanceAdministratorResource", new()
    {
        AdministratorType = "string",
        Login = "string",
        ManagedInstanceName = "string",
        ResourceGroupName = "string",
        Sid = "string",
        AdministratorName = "string",
        TenantId = "string",
    });
    
    example, err := sql.NewManagedInstanceAdministrator(ctx, "managedInstanceAdministratorResource", &sql.ManagedInstanceAdministratorArgs{
    AdministratorType: pulumi.String("string"),
    Login: pulumi.String("string"),
    ManagedInstanceName: pulumi.String("string"),
    ResourceGroupName: pulumi.String("string"),
    Sid: pulumi.String("string"),
    AdministratorName: pulumi.String("string"),
    TenantId: pulumi.String("string"),
    })
    
    var managedInstanceAdministratorResource = new ManagedInstanceAdministrator("managedInstanceAdministratorResource", ManagedInstanceAdministratorArgs.builder()
        .administratorType("string")
        .login("string")
        .managedInstanceName("string")
        .resourceGroupName("string")
        .sid("string")
        .administratorName("string")
        .tenantId("string")
        .build());
    
    managed_instance_administrator_resource = azure_native.sql.ManagedInstanceAdministrator("managedInstanceAdministratorResource",
        administrator_type="string",
        login="string",
        managed_instance_name="string",
        resource_group_name="string",
        sid="string",
        administrator_name="string",
        tenant_id="string")
    
    const managedInstanceAdministratorResource = new azure_native.sql.ManagedInstanceAdministrator("managedInstanceAdministratorResource", {
        administratorType: "string",
        login: "string",
        managedInstanceName: "string",
        resourceGroupName: "string",
        sid: "string",
        administratorName: "string",
        tenantId: "string",
    });
    
    type: azure-native:sql:ManagedInstanceAdministrator
    properties:
        administratorName: string
        administratorType: string
        login: string
        managedInstanceName: string
        resourceGroupName: string
        sid: string
        tenantId: string
    

    ManagedInstanceAdministrator 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 ManagedInstanceAdministrator resource accepts the following input properties:

    AdministratorType string | Pulumi.AzureNative.Sql.ManagedInstanceAdministratorType
    Type of the managed instance administrator.
    Login string
    Login name of the managed instance administrator.
    ManagedInstanceName string
    The name of the managed instance.
    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.
    Sid string
    SID (object ID) of the managed instance administrator.
    AdministratorName string
    TenantId string
    Tenant ID of the managed instance administrator.
    AdministratorType string | ManagedInstanceAdministratorType
    Type of the managed instance administrator.
    Login string
    Login name of the managed instance administrator.
    ManagedInstanceName string
    The name of the managed instance.
    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.
    Sid string
    SID (object ID) of the managed instance administrator.
    AdministratorName string
    TenantId string
    Tenant ID of the managed instance administrator.
    administratorType String | ManagedInstanceAdministratorType
    Type of the managed instance administrator.
    login String
    Login name of the managed instance administrator.
    managedInstanceName String
    The name of the managed instance.
    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.
    sid String
    SID (object ID) of the managed instance administrator.
    administratorName String
    tenantId String
    Tenant ID of the managed instance administrator.
    administratorType string | ManagedInstanceAdministratorType
    Type of the managed instance administrator.
    login string
    Login name of the managed instance administrator.
    managedInstanceName string
    The name of the managed instance.
    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.
    sid string
    SID (object ID) of the managed instance administrator.
    administratorName string
    tenantId string
    Tenant ID of the managed instance administrator.
    administrator_type str | ManagedInstanceAdministratorType
    Type of the managed instance administrator.
    login str
    Login name of the managed instance administrator.
    managed_instance_name str
    The name of the managed instance.
    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.
    sid str
    SID (object ID) of the managed instance administrator.
    administrator_name str
    tenant_id str
    Tenant ID of the managed instance administrator.
    administratorType String | "ActiveDirectory"
    Type of the managed instance administrator.
    login String
    Login name of the managed instance administrator.
    managedInstanceName String
    The name of the managed instance.
    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.
    sid String
    SID (object ID) of the managed instance administrator.
    administratorName String
    tenantId String
    Tenant ID of the managed instance administrator.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    Resource name.
    Type string
    Resource type.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    Resource name.
    Type string
    Resource type.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    Resource name.
    type String
    Resource type.
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    Resource name.
    type string
    Resource type.
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    Resource name.
    type str
    Resource type.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    Resource name.
    type String
    Resource type.

    Supporting Types

    ManagedInstanceAdministratorType, ManagedInstanceAdministratorTypeArgs

    ActiveDirectory
    ActiveDirectory
    ManagedInstanceAdministratorTypeActiveDirectory
    ActiveDirectory
    ActiveDirectory
    ActiveDirectory
    ActiveDirectory
    ActiveDirectory
    ACTIVE_DIRECTORY
    ActiveDirectory
    "ActiveDirectory"
    ActiveDirectory

    Import

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

    $ pulumi import azure-native:sql:ManagedInstanceAdministrator ActiveDirectory /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators/{administratorName} 
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Azure Native pulumi/pulumi-azure-native
    License
    Apache-2.0
    azure-native logo
    This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
    Azure Native v2.47.1 published on Monday, Jun 24, 2024 by Pulumi