Package com.pulumi.gcp.containeranalysis
Class Note
- java.lang.Object
-
- com.pulumi.resources.Resource
-
- com.pulumi.resources.CustomResource
-
- com.pulumi.gcp.containeranalysis.Note
-
public class Note extends com.pulumi.resources.CustomResource
A Container Analysis note is a high-level piece of metadata that describes a type of analysis that can be done for a resource. To get more information about Note, see: * [API documentation](https://cloud.google.com/container-analysis/api/reference/rest/) * How-to Guides * [Official Documentation](https://cloud.google.com/container-analysis/) * [Creating Attestations (Occurrences)](https://cloud.google.com/binary-authorization/docs/making-attestations) ## Example Usage ### Container Analysis Note Basic ```java package generated_program; import com.pulumi.Context; import com.pulumi.Pulumi; import com.pulumi.core.Output; import com.pulumi.gcp.containeranalysis.Note; import com.pulumi.gcp.containeranalysis.NoteArgs; import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityArgs; import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityHintArgs; 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 note = new Note("note", NoteArgs.builder() .attestationAuthority(NoteAttestationAuthorityArgs.builder() .hint(NoteAttestationAuthorityHintArgs.builder() .humanReadableName("Attestor Note") .build()) .build()) .build()); } } ``` ### Container Analysis Note Attestation Full ```java package generated_program; import com.pulumi.Context; import com.pulumi.Pulumi; import com.pulumi.core.Output; import com.pulumi.gcp.containeranalysis.Note; import com.pulumi.gcp.containeranalysis.NoteArgs; import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityArgs; import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityHintArgs; import com.pulumi.gcp.containeranalysis.inputs.NoteRelatedUrlArgs; 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 note = new Note("note", NoteArgs.builder() .attestationAuthority(NoteAttestationAuthorityArgs.builder() .hint(NoteAttestationAuthorityHintArgs.builder() .humanReadableName("Attestor Note") .build()) .build()) .expirationTime("2120-10-02T15:01:23.045123456Z") .longDescription("a longer description of test note") .relatedUrls( NoteRelatedUrlArgs.builder() .label("foo") .url("some.url") .build(), NoteRelatedUrlArgs.builder() .url("google.com") .build()) .shortDescription("test note") .build()); } } ``` ## Import Note can be imported using any of these accepted formats* `projects/{{project}}/notes/{{name}}` * `{{project}}/{{name}}` * `{{name}}` In Terraform v1.5.0 and later, use an [`import` block](https://developer.hashicorp.com/terraform/language/import) to import Note using one of the formats above. For exampletf import { id = "projects/{{project}}/notes/{{name}}" to = google_container_analysis_note.default } ```sh $ pulumi import gcp:containeranalysis/note:Note When using the [`terraform import` command](https://developer.hashicorp.com/terraform/cli/commands/import), Note can be imported using one of the formats above. For example ``` ```sh $ pulumi import gcp:containeranalysis/note:Note default projects/{{project}}/notes/{{name}} ``` ```sh $ pulumi import gcp:containeranalysis/note:Note default {{project}}/{{name}} ``` ```sh $ pulumi import gcp:containeranalysis/note:Note default {{name}} ```
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description com.pulumi.core.Output<NoteAttestationAuthority>
attestationAuthority()
com.pulumi.core.Output<java.lang.String>
createTime()
com.pulumi.core.Output<java.util.Optional<java.lang.String>>
expirationTime()
static Note
get(java.lang.String name, com.pulumi.core.Output<java.lang.String> id, NoteState state, com.pulumi.resources.CustomResourceOptions options)
Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.com.pulumi.core.Output<java.lang.String>
kind()
com.pulumi.core.Output<java.util.Optional<java.lang.String>>
longDescription()
com.pulumi.core.Output<java.lang.String>
name()
com.pulumi.core.Output<java.lang.String>
project()
com.pulumi.core.Output<java.util.Optional<java.util.List<java.lang.String>>>
relatedNoteNames()
com.pulumi.core.Output<java.util.Optional<java.util.List<NoteRelatedUrl>>>
relatedUrls()
com.pulumi.core.Output<java.util.Optional<java.lang.String>>
shortDescription()
com.pulumi.core.Output<java.lang.String>
updateTime()
-
-
-
Constructor Detail
-
Note
public Note(java.lang.String name)
- Parameters:
name
- The _unique_ name of the resulting resource.
-
Note
public Note(java.lang.String name, NoteArgs args)
- Parameters:
name
- The _unique_ name of the resulting resource.args
- The arguments to use to populate this resource's properties.
-
Note
public Note(java.lang.String name, NoteArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options)
- Parameters:
name
- The _unique_ name of the resulting resource.args
- The arguments to use to populate this resource's properties.options
- A bag of options that control this resource's behavior.
-
-
Method Detail
-
attestationAuthority
public com.pulumi.core.Output<NoteAttestationAuthority> attestationAuthority()
- Returns:
- Note kind that represents a logical attestation "role" or "authority". For example, an organization might have one AttestationAuthority for "QA" and one for "build". This Note is intended to act strictly as a grouping mechanism for the attached Occurrences (Attestations). This grouping mechanism also provides a security boundary, since IAM ACLs gate the ability for a principle to attach an Occurrence to a given Note. It also provides a single point of lookup to find all attached Attestation Occurrences, even if they don't all live in the same project. Structure is documented below.
-
createTime
public com.pulumi.core.Output<java.lang.String> createTime()
- Returns:
- The time this note was created.
-
expirationTime
public com.pulumi.core.Output<java.util.Optional<java.lang.String>> expirationTime()
- Returns:
- Time of expiration for this note. Leave empty if note does not expire.
-
kind
public com.pulumi.core.Output<java.lang.String> kind()
- Returns:
- The type of analysis this note describes
-
longDescription
public com.pulumi.core.Output<java.util.Optional<java.lang.String>> longDescription()
- Returns:
- A detailed description of the note
-
name
public com.pulumi.core.Output<java.lang.String> name()
- Returns:
- The name of the note.
-
project
public com.pulumi.core.Output<java.lang.String> project()
- Returns:
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
-
relatedNoteNames
public com.pulumi.core.Output<java.util.Optional<java.util.List<java.lang.String>>> relatedNoteNames()
- Returns:
- Names of other notes related to this note.
-
relatedUrls
public com.pulumi.core.Output<java.util.Optional<java.util.List<NoteRelatedUrl>>> relatedUrls()
- Returns:
- URLs associated with this note and related metadata. Structure is documented below.
-
shortDescription
public com.pulumi.core.Output<java.util.Optional<java.lang.String>> shortDescription()
- Returns:
- A one sentence description of the note.
-
updateTime
public com.pulumi.core.Output<java.lang.String> updateTime()
- Returns:
- The time this note was last updated.
-
get
public static Note get(java.lang.String name, com.pulumi.core.Output<java.lang.String> id, @Nullable NoteState state, @Nullable com.pulumi.resources.CustomResourceOptions options)
Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.- Parameters:
name
- The _unique_ name of the resulting resource.id
- The _unique_ provider ID of the resource to lookup.state
-options
- Optional settings to control the behavior of the CustomResource.
-
-