Add HCL examples for the tier 1 providers - #2986
Merged
Merged
Conversation
Add one Pulumi HCL (runtime: hcl) example per tier 1 provider: - aws-hcl-s3-folder: an S3 static website, mirroring aws-ts-s3-folder. - azure-hcl-static-website: a static website on Azure Blob Storage, using the Terraform azurerm provider. - gcp-hcl-webserver: a web server on a Compute Engine instance, mirroring gcp-go-webserver. - kubernetes-hcl-guestbook: the guestbook application, mirroring the existing guestbook family. Each example is covered by an integration test. The integration harness has no built-in prepare step for the hcl runtime, so a shared helpers.HCLPrepareProject runs `pulumi install` to fetch the language plugin and the bridged Terraform providers before the first update. Wire the new language into CI: `hcl` maps to the Hcl test-set suffix in scripts/changed-examples.sh, and the AwsHcl, AzureHcl, and GcpHcl sets join the full sweep now that their runners exist. The Kubernetes example runs under the existing minikube job via TestAccKubernetesGuestbook. `pulumi install` materializes sdks/<provider>/hcl.sdk.json files in HCL projects; ignore them as generated artifacts. Closes pulumi/home#4704.
CI resolved azurerm 5.x while the examples were verified locally against 4.x, where `azurerm_storage_blob.storage_container_name` still existed. In 5.x the blob requires `storage_container_id`, so look up the implicit `$web` container with a data source and reference it by ID. Pin each example's provider to its current major through `terraform.required_providers`, so local runs and CI resolve the same major and a future major release cannot break the nightly sweep.
iwahbe
marked this pull request as ready for review
August 25, 2026 08:35
There was a problem hiding this comment.
✅ No issues found
About Unblocked
Unblocked has been set up to automatically review your team's pull requests to identify genuine bugs and issues.
📖 Documentation — Learn more in our docs.
💬 Ask questions — Mention @unblocked to request a review or summary, or ask follow-up questions.
👍 Give feedback — React to comments with 👍 or 👎 to help us improve.
⚙️ Customize — Adjust settings in your preferences.
The google provider defaults deletion_protection to true, so every `pulumi destroy` of this example fails and the nightly GcpGo sweep has been red since the provider bump. Set it to false: the example's cluster is disposable by design.
jkodroff
approved these changes
Aug 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds one Pulumi HCL (
runtime: hcl) example per tier 1 provider:aws-hcl-s3-folder— an S3 static website, mirroringaws-ts-s3-folder(Terraformawsprovider).azure-hcl-static-website— a static website on Azure Blob Storage (Terraformazurerm+randomproviders).gcp-hcl-webserver— a web server on a Compute Engine instance, mirroringgcp-go-webserver(Terraformgoogleprovider).kubernetes-hcl-guestbook— the guestbook application, mirroring the existing guestbook family (Terraformkubernetesprovider).All providers resolve from the OpenTofu registry through
pulumi-terraform-provider, and the HCL language plugin auto-installs, so the examples need no dependency files.Test coverage
Each example has an integration test:
TestAccAwsHclS3Folder,TestAccAzureHcl(definitions-based),TestAccGcpHclWebserver, and akubernetes-hcl-guestbookentry inTestAccKubernetesGuestbook. The harness'sintegration.ProgramTesthas no prepare step for thehclruntime, so a sharedhelpers.HCLPrepareProjectrunspulumi installbefore the first update.CI wiring:
hclmaps to theHcltest-set suffix inscripts/changed-examples.sh, andAwsHcl,AzureHcl,GcpHcljoinall_test_sets()(their runners exist). The Kubernetes example runs under the existing minikube job.All four were verified locally end to end: the AWS, Azure, and GCP tests pass (deploy, HTTP validation, destroy), and the guestbook was deployed to a kind cluster with MetalLB and served the expected page through its
LoadBalancerIP.pulumi installmaterializessdks/<provider>/hcl.sdk.jsonin HCL projects; these are generated artifacts and are now gitignored.Closes pulumi/home#4704.