https://pulumi.com logo
#general
Title
# general
a

adorable-action-51248

03/20/2020, 10:16 AM
Hello ! I was wondering how can I best write a (js) script that creates a GCE disk from the latest and non-pending snapshot ?
g

gentle-diamond-70147

03/20/2020, 4:17 PM
The resource documentation for a GCE disk is here - https://www.pulumi.com/docs/reference/pkg/nodejs/pulumi/gcp/compute/#Disk.
Looks like we don't have a built-in way to query for snapshots, so you could use the GCP SDK to do this and provide the result into the Pulumi
gcp.compute.Disk
resource.
a

adorable-action-51248

03/20/2020, 4:34 PM
ok, that’s what i am doing now.
👍 thanks !