The Simplest Way to Make Pulumi and Tekton Work Like They Should
Teams pair pulumi and tekton to run cloud updates inside native Kubernetes build pipelines. Tekton runs the tasks in pods, while Pulumi reads code and updates cloud resources. This setup keeps app builds and cloud changes in one place. When a developer pushes code, a webhook wakes up the cluster. Tekton spins up a fresh pod to test the code and apply cloud updates. Both tools run well on their own, but linking them takes care. How login and data work for pulumi and tekton Every pipeline run
Your coding agents run with your access.
Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.
Teams pair pulumi and tekton to run cloud updates inside native Kubernetes build pipelines. Tekton runs the tasks in pods, while Pulumi reads code and updates cloud resources.
This setup keeps app builds and cloud changes in one place. When a developer pushes code, a webhook wakes up the cluster. Tekton spins up a fresh pod to test the code and apply cloud updates. Both tools run well on their own, but linking them takes care.
How login and data work for pulumi and tekton
Every pipeline run needs two sets of keys to do its job. First, Pulumi needs a key to read and write its state file. Second, it needs cloud provider roles to build servers, networks, and databases.
In a standard setup, Tekton mounts Kubernetes secrets into the task pod. The pod starts up, reads those keys, and logs into the state backend. Next, Pulumi compares the code in Git with the live cloud state. It builds a plan and sends API calls to the cloud provider.
Tekton passes data between steps using shared disk volumes called workspaces. One task clones the Git repo onto the shared disk. The next task runs Pulumi in that same folder to check the plan. A final task applies the changes and writes the output to the build log.
This flow keeps each step isolated inside its own container image. Teams can pin exact tool versions for every step in the pipeline. When the run ends, Kubernetes deletes the pod and clears the temporary disk.
Common failure modes and how to scope roles
Many teams start by putting one broad cloud admin key into a shared secret. Every Tekton pipeline in the namespace then uses that same admin key. If one test pipeline breaks or leaks a log, the whole cloud account is at risk. Broad keys also make it hard to see which team changed a resource.
Static keys in Kubernetes secrets also go stale or get out of sync. When an engineer rotates a key in the cloud console, the pipeline breaks. Someone must update the secret by hand in every cluster namespace.
Pulumi Policy as Code + End-to-End Encryption: architecture patterns and best practices
Continue reading? Get the full guide.
Free. No spam. Unsubscribe anytime.
Instead of static keys, bind Kubernetes service accounts to cloud identity roles. Give each project its own namespace and its own service account. Map that account to a narrow cloud role that only touches one stage. A test pipeline should never hold keys that can write to production.
State locks cause another common problem during busy work hours. If two commits trigger two Tekton runs at the same time, they will clash. The first pod locks the state file, and the second pod fails right away. Set up your pipeline rules to queue runs or cancel older builds on the same branch.
Unlogged runs and leaked data in build logs also hurt security. Pulumi plans can sometimes print raw database fields if outputs are not marked secret. Always mark sensitive stack outputs as secret in your code before running a build. If your pipeline queries live data, apply data masking to rewrite emails or card numbers in results.
Keeping pipeline runs fast and clean
Fresh pods start with an empty disk on every single pipeline run. Downloading language packages and cloud plugins on every build wastes a lot of time. Build a custom container image that bakes in your runtime and common plugins.
Keep your stack sizes small so each Tekton task finishes fast. Split large cloud setups into smaller stacks for networking, data, and apps. Small stacks cut down state check times and reduce the blast radius of bad runs.
Also set strict time limits on every Tekton task in your cluster. If a cloud API hangs, a stuck pod can hold the state lock for hours. A clear timeout kills the stuck pod and lets the team fix the lock fast.
Govern statements and responses across databases and APIs
Good config and scoped roles are needed setup. They do not check single queries in flight or mask sensitive fields in returned rows. Across Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, and internal HTTP endpoints, hoop.dev runs beside each supported service as an open-source proxy, a sidecar for your database or API.
First, hoop.dev guardrails block banned queries before they run. Then hoop.dev data masking rewrites matched sensitive values in responses in memory. The audit trail records every statement and verdict per resource. Furthermore, hoop.dev holds SOC 2 Type II and is open source on GitHub.
Frequently asked questions
How do we pass outputs from a Pulumi task to later Tekton steps?
Write the stack outputs to a file inside the Tekton workspace or task results folder. The next step in the pipeline can read that file from the shared workspace.
What happens if a Tekton pod crashes while Pulumi is updating the cloud?
If a pod dies mid-run, the state file stays locked to prevent corrupt data. An engineer must check the cloud resources and run a cancel command to clear the lock.
Should we run previews and updates in the same Tekton pipeline?
Run previews on pull requests and run updates only after code merges to your main branch. Keeping them in separate pipelines stops untested code from changing live cloud resources.
Related guides
In this post