1. Packages
  2. Azure Native
  3. API Docs
  4. datashare
  5. Share
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.datashare.Share

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

    A share data transfer object. Azure REST API version: 2021-08-01. Prior API version in Azure Native 1.x: 2020-09-01.

    Example Usage

    Shares_Create

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureNative = Pulumi.AzureNative;
    
    return await Deployment.RunAsync(() => 
    {
        var share = new AzureNative.DataShare.Share("share", new()
        {
            AccountName = "Account1",
            Description = "share description",
            ResourceGroupName = "SampleResourceGroup",
            ShareKind = AzureNative.DataShare.ShareKind.CopyBased,
            ShareName = "Share1",
            Terms = "Confidential",
        });
    
    });
    
    package main
    
    import (
    	datashare "github.com/pulumi/pulumi-azure-native-sdk/datashare/v2"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := datashare.NewShare(ctx, "share", &datashare.ShareArgs{
    			AccountName:       pulumi.String("Account1"),
    			Description:       pulumi.String("share description"),
    			ResourceGroupName: pulumi.String("SampleResourceGroup"),
    			ShareKind:         pulumi.String(datashare.ShareKindCopyBased),
    			ShareName:         pulumi.String("Share1"),
    			Terms:             pulumi.String("Confidential"),
    		})
    		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.datashare.Share;
    import com.pulumi.azurenative.datashare.ShareArgs;
    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 share = new Share("share", ShareArgs.builder()
                .accountName("Account1")
                .description("share description")
                .resourceGroupName("SampleResourceGroup")
                .shareKind("CopyBased")
                .shareName("Share1")
                .terms("Confidential")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_azure_native as azure_native
    
    share = azure_native.datashare.Share("share",
        account_name="Account1",
        description="share description",
        resource_group_name="SampleResourceGroup",
        share_kind=azure_native.datashare.ShareKind.COPY_BASED,
        share_name="Share1",
        terms="Confidential")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure_native from "@pulumi/azure-native";
    
    const share = new azure_native.datashare.Share("share", {
        accountName: "Account1",
        description: "share description",
        resourceGroupName: "SampleResourceGroup",
        shareKind: azure_native.datashare.ShareKind.CopyBased,
        shareName: "Share1",
        terms: "Confidential",
    });
    
    resources:
      share:
        type: azure-native:datashare:Share
        properties:
          accountName: Account1
          description: share description
          resourceGroupName: SampleResourceGroup
          shareKind: CopyBased
          shareName: Share1
          terms: Confidential
    

    Create Share Resource

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

    Constructor syntax

    new Share(name: string, args: ShareArgs, opts?: CustomResourceOptions);
    @overload
    def Share(resource_name: str,
              args: ShareArgs,
              opts: Optional[ResourceOptions] = None)
    
    @overload
    def Share(resource_name: str,
              opts: Optional[ResourceOptions] = None,
              account_name: Optional[str] = None,
              resource_group_name: Optional[str] = None,
              description: Optional[str] = None,
              share_kind: Optional[Union[str, ShareKind]] = None,
              share_name: Optional[str] = None,
              terms: Optional[str] = None)
    func NewShare(ctx *Context, name string, args ShareArgs, opts ...ResourceOption) (*Share, error)
    public Share(string name, ShareArgs args, CustomResourceOptions? opts = null)
    public Share(String name, ShareArgs args)
    public Share(String name, ShareArgs args, CustomResourceOptions options)
    
    type: azure-native:datashare:Share
    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 ShareArgs
    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 ShareArgs
    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 ShareArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ShareArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ShareArgs
    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_nativeShareResource = new AzureNative.DataShare.Share("azure-nativeShareResource", new()
    {
        AccountName = "string",
        ResourceGroupName = "string",
        Description = "string",
        ShareKind = "string",
        ShareName = "string",
        Terms = "string",
    });
    
    example, err := datashare.NewShare(ctx, "azure-nativeShareResource", &datashare.ShareArgs{
    AccountName: pulumi.String("string"),
    ResourceGroupName: pulumi.String("string"),
    Description: pulumi.String("string"),
    ShareKind: pulumi.String("string"),
    ShareName: pulumi.String("string"),
    Terms: pulumi.String("string"),
    })
    
    var azure_nativeShareResource = new Share("azure-nativeShareResource", ShareArgs.builder()
        .accountName("string")
        .resourceGroupName("string")
        .description("string")
        .shareKind("string")
        .shareName("string")
        .terms("string")
        .build());
    
    azure_native_share_resource = azure_native.datashare.Share("azure-nativeShareResource",
        account_name="string",
        resource_group_name="string",
        description="string",
        share_kind="string",
        share_name="string",
        terms="string")
    
    const azure_nativeShareResource = new azure_native.datashare.Share("azure-nativeShareResource", {
        accountName: "string",
        resourceGroupName: "string",
        description: "string",
        shareKind: "string",
        shareName: "string",
        terms: "string",
    });
    
    type: azure-native:datashare:Share
    properties:
        accountName: string
        description: string
        resourceGroupName: string
        shareKind: string
        shareName: string
        terms: string
    

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

    AccountName string
    The name of the share account.
    ResourceGroupName string
    The resource group name.
    Description string
    Share description.
    ShareKind string | Pulumi.AzureNative.DataShare.ShareKind
    Share kind.
    ShareName string
    The name of the share.
    Terms string
    Share terms.
    AccountName string
    The name of the share account.
    ResourceGroupName string
    The resource group name.
    Description string
    Share description.
    ShareKind string | ShareKind
    Share kind.
    ShareName string
    The name of the share.
    Terms string
    Share terms.
    accountName String
    The name of the share account.
    resourceGroupName String
    The resource group name.
    description String
    Share description.
    shareKind String | ShareKind
    Share kind.
    shareName String
    The name of the share.
    terms String
    Share terms.
    accountName string
    The name of the share account.
    resourceGroupName string
    The resource group name.
    description string
    Share description.
    shareKind string | ShareKind
    Share kind.
    shareName string
    The name of the share.
    terms string
    Share terms.
    account_name str
    The name of the share account.
    resource_group_name str
    The resource group name.
    description str
    Share description.
    share_kind str | ShareKind
    Share kind.
    share_name str
    The name of the share.
    terms str
    Share terms.
    accountName String
    The name of the share account.
    resourceGroupName String
    The resource group name.
    description String
    Share description.
    shareKind String | "CopyBased" | "InPlace"
    Share kind.
    shareName String
    The name of the share.
    terms String
    Share terms.

    Outputs

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

    CreatedAt string
    Time at which the share was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    Name of the azure resource
    ProvisioningState string
    Gets or sets the provisioning state
    SystemData Pulumi.AzureNative.DataShare.Outputs.SystemDataResponse
    System Data of the Azure resource.
    Type string
    Type of the azure resource
    UserEmail string
    Email of the user who created the resource
    UserName string
    Name of the user who created the resource
    CreatedAt string
    Time at which the share was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    Name of the azure resource
    ProvisioningState string
    Gets or sets the provisioning state
    SystemData SystemDataResponse
    System Data of the Azure resource.
    Type string
    Type of the azure resource
    UserEmail string
    Email of the user who created the resource
    UserName string
    Name of the user who created the resource
    createdAt String
    Time at which the share was created.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    Name of the azure resource
    provisioningState String
    Gets or sets the provisioning state
    systemData SystemDataResponse
    System Data of the Azure resource.
    type String
    Type of the azure resource
    userEmail String
    Email of the user who created the resource
    userName String
    Name of the user who created the resource
    createdAt string
    Time at which the share was created.
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    Name of the azure resource
    provisioningState string
    Gets or sets the provisioning state
    systemData SystemDataResponse
    System Data of the Azure resource.
    type string
    Type of the azure resource
    userEmail string
    Email of the user who created the resource
    userName string
    Name of the user who created the resource
    created_at str
    Time at which the share was created.
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    Name of the azure resource
    provisioning_state str
    Gets or sets the provisioning state
    system_data SystemDataResponse
    System Data of the Azure resource.
    type str
    Type of the azure resource
    user_email str
    Email of the user who created the resource
    user_name str
    Name of the user who created the resource
    createdAt String
    Time at which the share was created.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    Name of the azure resource
    provisioningState String
    Gets or sets the provisioning state
    systemData Property Map
    System Data of the Azure resource.
    type String
    Type of the azure resource
    userEmail String
    Email of the user who created the resource
    userName String
    Name of the user who created the resource

    Supporting Types

    ShareKind, ShareKindArgs

    CopyBased
    CopyBased
    InPlace
    InPlace
    ShareKindCopyBased
    CopyBased
    ShareKindInPlace
    InPlace
    CopyBased
    CopyBased
    InPlace
    InPlace
    CopyBased
    CopyBased
    InPlace
    InPlace
    COPY_BASED
    CopyBased
    IN_PLACE
    InPlace
    "CopyBased"
    CopyBased
    "InPlace"
    InPlace

    SystemDataResponse, SystemDataResponseArgs

    CreatedAt string
    The timestamp of resource creation (UTC).
    CreatedBy string
    The identity that created the resource.
    CreatedByType string
    The type of identity that created the resource.
    LastModifiedAt string
    The type of identity that last modified the resource.
    LastModifiedBy string
    The identity that last modified the resource.
    LastModifiedByType string
    The type of identity that last modified the resource.
    CreatedAt string
    The timestamp of resource creation (UTC).
    CreatedBy string
    The identity that created the resource.
    CreatedByType string
    The type of identity that created the resource.
    LastModifiedAt string
    The type of identity that last modified the resource.
    LastModifiedBy string
    The identity that last modified the resource.
    LastModifiedByType string
    The type of identity that last modified the resource.
    createdAt String
    The timestamp of resource creation (UTC).
    createdBy String
    The identity that created the resource.
    createdByType String
    The type of identity that created the resource.
    lastModifiedAt String
    The type of identity that last modified the resource.
    lastModifiedBy String
    The identity that last modified the resource.
    lastModifiedByType String
    The type of identity that last modified the resource.
    createdAt string
    The timestamp of resource creation (UTC).
    createdBy string
    The identity that created the resource.
    createdByType string
    The type of identity that created the resource.
    lastModifiedAt string
    The type of identity that last modified the resource.
    lastModifiedBy string
    The identity that last modified the resource.
    lastModifiedByType string
    The type of identity that last modified the resource.
    created_at str
    The timestamp of resource creation (UTC).
    created_by str
    The identity that created the resource.
    created_by_type str
    The type of identity that created the resource.
    last_modified_at str
    The type of identity that last modified the resource.
    last_modified_by str
    The identity that last modified the resource.
    last_modified_by_type str
    The type of identity that last modified the resource.
    createdAt String
    The timestamp of resource creation (UTC).
    createdBy String
    The identity that created the resource.
    createdByType String
    The type of identity that created the resource.
    lastModifiedAt String
    The type of identity that last modified the resource.
    lastModifiedBy String
    The identity that last modified the resource.
    lastModifiedByType String
    The type of identity that last modified the resource.

    Import

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

    $ pulumi import azure-native:datashare:Share Share1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataShare/accounts/{accountName}/shares/{shareName} 
    

    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