Hi folks! I'm using the Fastly CDN tool to create ...
# general
Hi folks! I'm using the Fastly CDN tool to create a GCS-backed service. Everything works great, aside from one piece: adding a VCL Snippet. (Fastly recommends this in their by-hand instructions.) I want to create a new https://www.pulumi.com/registry/packages/fastly/api-docs/servicedynamicsnippetcontentv1/#inputs --but it looks like I need a snippet ID of an existing snippet to create a new one. Chicken/Egg? Do you folks have some ideas?
Copy code
fixCachingVCL, err := fastly.NewServiceDynamicSnippetContentv1(ctx, "X-Http-Method-Override",
		Content:   pulumi.String("unset req.http.X-Http-Method-Override;"),
		ServiceId: bitmovincdn.ID(),
		SnippetId: , // Need a real one. manual?
I realized that I had not created the Dynamicsnippets section of my original Servicev1. Now I'm struggling trying to get the particular SnippetId out of the OuputArray.
Ah, that's where "lifting" comes into it! This works:
Copy code
SnippetId: bitmovincdn.Dynamicsnippets.Index(<http://pulumi.Int|pulumi.Int>(0)).SnippetId().Elem(),