Class Account
Allows management of a Google Cloud Platform service account
Creation of service accounts is eventually consistent, and that can lead to errors when you try to apply ACLs to service accounts immediately after creation.
Example Usage
using Pulumi;
using Gcp = Pulumi.Gcp;
class MyStack : Stack
{
public MyStack()
{
var serviceAccount = new Gcp.ServiceAccount.Account("serviceAccount", new Gcp.ServiceAccount.AccountArgs
{
AccountId = "service_account_id",
DisplayName = "Service Account",
});
}
}
Inherited Members
Namespace: Pulumi.Gcp.ServiceAccount
Assembly: Pulumi.Gcp.dll
Syntax
public class Account : CustomResource
Constructors
View SourceAccount(String, AccountArgs, CustomResourceOptions)
Create a Account resource with the given unique name, arguments, and options.
Declaration
public Account(string name, AccountArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| AccountArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceAccountId
The account id that is used to generate the service
account email address and a stable unique id. It is unique within a project,
must be 6-30 characters long, and match the regular expression a-z
to comply with RFC1035. Changing this forces a new service account to be created.
Declaration
public Output<string> AccountId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Description
A text description of the service account. Must be less than or equal to 256 UTF-8 bytes.
Declaration
public Output<string> Description { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
DisplayName
The display name for the service account. Can be updated without creating a new resource.
Declaration
public Output<string> DisplayName { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
The e-mail address of the service account. This value
should be referenced from any gcp.organizations.getIAMPolicy data sources
that would grant the service account privileges.
Declaration
public Output<string> Email { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Name
The fully-qualified name of the service account.
Declaration
public Output<string> Name { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Project
The ID of the project that the service account will be created in. Defaults to the provider project configuration.
Declaration
public Output<string> Project { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
UniqueId
The unique id of the service account.
Declaration
public Output<string> UniqueId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, AccountState, CustomResourceOptions)
Get an existing Account resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static Account Get(string name, Input<string> id, AccountState 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. |
| AccountState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| Account |