Show / Hide Table of Contents

Class RandomUuid

The resource random..RandomUuid generates random uuid string that is intended to be used as unique identifiers for other resources.

This resource uses the hashicorp/go-uuid to generate a UUID-formatted string for use with services needed a unique string identifier.

Example Usage

using Pulumi;
using Azure = Pulumi.Azure;
using Random = Pulumi.Random;

class MyStack : Stack
{
public MyStack()
{
    var testRandomUuid = new Random.RandomUuid("testRandomUuid", new Random.RandomUuidArgs
    {
    });
    var testResourceGroup = new Azure.Core.ResourceGroup("testResourceGroup", new Azure.Core.ResourceGroupArgs
    {
        Location = "Central US",
    });
}

}
Inheritance
System.Object
Resource
CustomResource
RandomUuid
Inherited Members
CustomResource.Id
Resource.GetResourceType()
Resource.GetResourceName()
Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.Random
Assembly: Pulumi.Random.dll
Syntax
public class RandomUuid : CustomResource

Constructors

View Source

RandomUuid(String, RandomUuidArgs, CustomResourceOptions)

Create a RandomUuid resource with the given unique name, arguments, and options.

Declaration
public RandomUuid(string name, RandomUuidArgs args = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

RandomUuidArgs args

The arguments used to populate this resource's properties

CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

Keepers

Arbitrary map of values that, when changed, will trigger a new uuid to be generated. See the main provider documentation for more information.

Declaration
public Output<ImmutableDictionary<string, object>> Keepers { get; }
Property Value
Type Description
Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.Object>>
View Source

Result

The generated uuid presented in string format.

Declaration
public Output<string> Result { get; }
Property Value
Type Description
Output<System.String>

Methods

View Source

Get(String, Input<String>, RandomUuidState, CustomResourceOptions)

Get an existing RandomUuid resource's state with the given name, ID, and optional extra properties used to qualify the lookup.

Declaration
public static RandomUuid Get(string name, Input<string> id, RandomUuidState state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Input<System.String> id

The unique provider ID of the resource to lookup.

RandomUuidState state

Any extra arguments used during the lookup.

CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
RandomUuid
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.