Class ProjectMetadata
Authoritatively manages metadata common to all instances for a project in GCE. For more information see the official documentation and API.
Note: This resource manages all project-level metadata including project-level ssh keys. Keys unset in config but set on the server will be removed. If you want to manage only single key/value pairs within the project metadata rather than the entire set, then use google_compute_project_metadata_item.
Example Usage
using Pulumi;
using Gcp = Pulumi.Gcp;
class MyStack : Stack
{
public MyStack()
{
var @default = new Gcp.Compute.ProjectMetadata("default", new Gcp.Compute.ProjectMetadataArgs
{
Metadata =
{
{ "13", "42" },
{ "fizz", "buzz" },
{ "foo", "bar" },
},
});
}
}
Inherited Members
Namespace: Pulumi.Gcp.Compute
Assembly: Pulumi.Gcp.dll
Syntax
public class ProjectMetadata : CustomResource
Constructors
View SourceProjectMetadata(String, ProjectMetadataArgs, CustomResourceOptions)
Create a ProjectMetadata resource with the given unique name, arguments, and options.
Declaration
public ProjectMetadata(string name, ProjectMetadataArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| ProjectMetadataArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceMetadata
A series of key value pairs.
Declaration
public Output<ImmutableDictionary<string, string>> Metadata { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.String>> |
Project
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
Declaration
public Output<string> Project { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, ProjectMetadataState, CustomResourceOptions)
Get an existing ProjectMetadata resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static ProjectMetadata Get(string name, Input<string> id, ProjectMetadataState 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. |
| ProjectMetadataState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| ProjectMetadata |