1. Packages
  2. Azure Native
  3. API Docs
  4. dbforpostgresql
  5. SingleServerServerAdministrator
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Azure Native v3.3.0 published on Monday, Apr 28, 2025 by Pulumi

azure-native.dbforpostgresql.SingleServerServerAdministrator

Explore with Pulumi AI

azure-native logo
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Azure Native v3.3.0 published on Monday, Apr 28, 2025 by Pulumi

    Represents a and external administrator to be created.

    Uses Azure REST API version 2017-12-01.

    Example Usage

    ServerAdministratorCreate

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureNative = Pulumi.AzureNative;
    
    return await Deployment.RunAsync(() => 
    {
        var singleServerServerAdministrator = new AzureNative.DBforPostgreSQL.SingleServerServerAdministrator("singleServerServerAdministrator", new()
        {
            AdministratorType = AzureNative.DBforPostgreSQL.AdministratorType.ActiveDirectory,
            Login = "bob@contoso.com",
            ResourceGroupName = "testrg",
            ServerName = "pgtestsvc4",
            Sid = "c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c",
            TenantId = "c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c",
        });
    
    });
    
    package main
    
    import (
    	dbforpostgresql "github.com/pulumi/pulumi-azure-native-sdk/dbforpostgresql/v3"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := dbforpostgresql.NewSingleServerServerAdministrator(ctx, "singleServerServerAdministrator", &dbforpostgresql.SingleServerServerAdministratorArgs{
    			AdministratorType: pulumi.String(dbforpostgresql.AdministratorTypeActiveDirectory),
    			Login:             pulumi.String("bob@contoso.com"),
    			ResourceGroupName: pulumi.String("testrg"),
    			ServerName:        pulumi.String("pgtestsvc4"),
    			Sid:               pulumi.String("c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c"),
    			TenantId:          pulumi.String("c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c"),
    		})
    		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.dbforpostgresql.SingleServerServerAdministrator;
    import com.pulumi.azurenative.dbforpostgresql.SingleServerServerAdministratorArgs;
    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 singleServerServerAdministrator = new SingleServerServerAdministrator("singleServerServerAdministrator", SingleServerServerAdministratorArgs.builder()
                .administratorType("ActiveDirectory")
                .login("bob@contoso.com")
                .resourceGroupName("testrg")
                .serverName("pgtestsvc4")
                .sid("c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c")
                .tenantId("c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c")
                .build());
    
        }
    }
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure_native from "@pulumi/azure-native";
    
    const singleServerServerAdministrator = new azure_native.dbforpostgresql.SingleServerServerAdministrator("singleServerServerAdministrator", {
        administratorType: azure_native.dbforpostgresql.AdministratorType.ActiveDirectory,
        login: "bob@contoso.com",
        resourceGroupName: "testrg",
        serverName: "pgtestsvc4",
        sid: "c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c",
        tenantId: "c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c",
    });
    
    import pulumi
    import pulumi_azure_native as azure_native
    
    single_server_server_administrator = azure_native.dbforpostgresql.SingleServerServerAdministrator("singleServerServerAdministrator",
        administrator_type=azure_native.dbforpostgresql.AdministratorType.ACTIVE_DIRECTORY,
        login="bob@contoso.com",
        resource_group_name="testrg",
        server_name="pgtestsvc4",
        sid="c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c",
        tenant_id="c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c")
    
    resources:
      singleServerServerAdministrator:
        type: azure-native:dbforpostgresql:SingleServerServerAdministrator
        properties:
          administratorType: ActiveDirectory
          login: bob@contoso.com
          resourceGroupName: testrg
          serverName: pgtestsvc4
          sid: c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c
          tenantId: c6b82b90-a647-49cb-8a62-0d2d3cb7ac7c
    

    Create SingleServerServerAdministrator Resource

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

    Constructor syntax

    new SingleServerServerAdministrator(name: string, args: SingleServerServerAdministratorArgs, opts?: CustomResourceOptions);
    @overload
    def SingleServerServerAdministrator(resource_name: str,
                                        args: SingleServerServerAdministratorArgs,
                                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def SingleServerServerAdministrator(resource_name: str,
                                        opts: Optional[ResourceOptions] = None,
                                        administrator_type: Optional[Union[str, AdministratorType]] = None,
                                        login: Optional[str] = None,
                                        resource_group_name: Optional[str] = None,
                                        server_name: Optional[str] = None,
                                        sid: Optional[str] = None,
                                        tenant_id: Optional[str] = None)
    func NewSingleServerServerAdministrator(ctx *Context, name string, args SingleServerServerAdministratorArgs, opts ...ResourceOption) (*SingleServerServerAdministrator, error)
    public SingleServerServerAdministrator(string name, SingleServerServerAdministratorArgs args, CustomResourceOptions? opts = null)
    public SingleServerServerAdministrator(String name, SingleServerServerAdministratorArgs args)
    public SingleServerServerAdministrator(String name, SingleServerServerAdministratorArgs args, CustomResourceOptions options)
    
    type: azure-native:dbforpostgresql:SingleServerServerAdministrator
    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 SingleServerServerAdministratorArgs
    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 SingleServerServerAdministratorArgs
    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 SingleServerServerAdministratorArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SingleServerServerAdministratorArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SingleServerServerAdministratorArgs
    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 azure_nativeSingleServerServerAdministratorResource = new AzureNative.DBforPostgreSQL.SingleServerServerAdministrator("azure-nativeSingleServerServerAdministratorResource", new()
    {
        AdministratorType = "string",
        Login = "string",
        ResourceGroupName = "string",
        ServerName = "string",
        Sid = "string",
        TenantId = "string",
    });
    
    example, err := dbforpostgresql.NewSingleServerServerAdministrator(ctx, "azure-nativeSingleServerServerAdministratorResource", &dbforpostgresql.SingleServerServerAdministratorArgs{
    	AdministratorType: pulumi.String("string"),
    	Login:             pulumi.String("string"),
    	ResourceGroupName: pulumi.String("string"),
    	ServerName:        pulumi.String("string"),
    	Sid:               pulumi.String("string"),
    	TenantId:          pulumi.String("string"),
    })
    
    var azure_nativeSingleServerServerAdministratorResource = new com.pulumi.azurenative.dbforpostgresql.SingleServerServerAdministrator("azure-nativeSingleServerServerAdministratorResource", com.pulumi.azurenative.dbforpostgresql.SingleServerServerAdministratorArgs.builder()
        .administratorType("string")
        .login("string")
        .resourceGroupName("string")
        .serverName("string")
        .sid("string")
        .tenantId("string")
        .build());
    
    azure_native_single_server_server_administrator_resource = azure_native.dbforpostgresql.SingleServerServerAdministrator("azure-nativeSingleServerServerAdministratorResource",
        administrator_type="string",
        login="string",
        resource_group_name="string",
        server_name="string",
        sid="string",
        tenant_id="string")
    
    const azure_nativeSingleServerServerAdministratorResource = new azure_native.dbforpostgresql.SingleServerServerAdministrator("azure-nativeSingleServerServerAdministratorResource", {
        administratorType: "string",
        login: "string",
        resourceGroupName: "string",
        serverName: "string",
        sid: "string",
        tenantId: "string",
    });
    
    type: azure-native:dbforpostgresql:SingleServerServerAdministrator
    properties:
        administratorType: string
        login: string
        resourceGroupName: string
        serverName: string
        sid: string
        tenantId: string
    

    SingleServerServerAdministrator Resource Properties

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

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The SingleServerServerAdministrator resource accepts the following input properties:

    AdministratorType string | Pulumi.AzureNative.DBforPostgreSQL.AdministratorType
    The type of administrator.
    Login string
    The server administrator login account name.
    ResourceGroupName string
    The name of the resource group. The name is case insensitive.
    ServerName string
    The name of the server.
    Sid string
    The server administrator Sid (Secure ID).
    TenantId string
    The server Active Directory Administrator tenant id.
    AdministratorType string | AdministratorType
    The type of administrator.
    Login string
    The server administrator login account name.
    ResourceGroupName string
    The name of the resource group. The name is case insensitive.
    ServerName string
    The name of the server.
    Sid string
    The server administrator Sid (Secure ID).
    TenantId string
    The server Active Directory Administrator tenant id.
    administratorType String | AdministratorType
    The type of administrator.
    login String
    The server administrator login account name.
    resourceGroupName String
    The name of the resource group. The name is case insensitive.
    serverName String
    The name of the server.
    sid String
    The server administrator Sid (Secure ID).
    tenantId String
    The server Active Directory Administrator tenant id.
    administratorType string | AdministratorType
    The type of administrator.
    login string
    The server administrator login account name.
    resourceGroupName string
    The name of the resource group. The name is case insensitive.
    serverName string
    The name of the server.
    sid string
    The server administrator Sid (Secure ID).
    tenantId string
    The server Active Directory Administrator tenant id.
    administrator_type str | AdministratorType
    The type of administrator.
    login str
    The server administrator login account name.
    resource_group_name str
    The name of the resource group. The name is case insensitive.
    server_name str
    The name of the server.
    sid str
    The server administrator Sid (Secure ID).
    tenant_id str
    The server Active Directory Administrator tenant id.
    administratorType String | "ActiveDirectory"
    The type of administrator.
    login String
    The server administrator login account name.
    resourceGroupName String
    The name of the resource group. The name is case insensitive.
    serverName String
    The name of the server.
    sid String
    The server administrator Sid (Secure ID).
    tenantId String
    The server Active Directory Administrator tenant id.

    Outputs

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

    AzureApiVersion string
    The Azure API version of the resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    The name of the resource
    Type string
    The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
    AzureApiVersion string
    The Azure API version of the resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    The name of the resource
    Type string
    The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
    azureApiVersion String
    The Azure API version of the resource.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    The name of the resource
    type String
    The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
    azureApiVersion string
    The Azure API version of the resource.
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    The name of the resource
    type string
    The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
    azure_api_version str
    The Azure API version of the resource.
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    The name of the resource
    type str
    The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
    azureApiVersion String
    The Azure API version of the resource.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    The name of the resource
    type String
    The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"

    Supporting Types

    AdministratorType, AdministratorTypeArgs

    ActiveDirectory
    ActiveDirectory
    AdministratorTypeActiveDirectory
    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:dbforpostgresql:SingleServerServerAdministrator activeDirectory /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/servers/{serverName}/administrators/activeDirectory 
    

    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 v2 docs if using the v2 version of this package.
    Azure Native v3.3.0 published on Monday, Apr 28, 2025 by Pulumi