The Simplest Way to Make Portworx and Pulumi Work Like They Should
Teams pair portworx and pulumi to set up container storage through code. Pulumi builds the cluster resources, and Portworx manages the disks for stateful apps. This workflow turns manual storage tasks into repeatable code deployments. Platform teams define storage classes, volume claims, and backup rules in one place. Then they run their pipeline to build the same storage setup across every cluster. How portworx and pulumi share permissions and data Pulumi needs cluster rights to install and
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 portworx and pulumi to set up container storage through code. Pulumi builds the cluster resources, and Portworx manages the disks for stateful apps.
This workflow turns manual storage tasks into repeatable code deployments. Platform teams define storage classes, volume claims, and backup rules in one place. Then they run their pipeline to build the same storage setup across every cluster.
How portworx and pulumi share permissions and data
Pulumi needs cluster rights to install and manage the Portworx operator. First, the deployment tool logs in to the Kubernetes API using a service account. Next, it writes custom resources that tell the storage operator how to run.
The operator reads those specs and claims raw block disks from the cloud provider. It pools those disks together and creates virtual volumes for your apps. Pulumi tracks the state of those Kubernetes objects in its own backend store.
Portworx also needs its own cloud permissions to attach and detach node disks. You set up an identity role in your cloud account for the storage nodes. Pulumi assigns this role to the worker nodes when it builds the cluster.
During an update, the code runner checks its state file against the live cluster. If a team changes a storage class size in code, the tool sends the change. The storage layer then resizes the volume or updates the replication factor.
Common failure modes and how to scope roles
Many teams fail by giving the deployment runner full cluster admin rights forever. A shared service account with broad tokens creates a major security risk. If that token leaks, an attacker can delete volumes or read sensitive cluster secrets.
Another common bug happens when someone changes storage settings by hand in the cluster. The next time the code pipeline runs, it overwrites those manual fixes. This state drift can break live databases or drop active volume mounts.
Pulumi Policy as Code + End-to-End Encryption: architecture patterns and best practices
Continue reading? Get the full guide.
Free. No spam. Unsubscribe anytime.
Unlogged changes to storage classes also hurt audit efforts during an incident. When ten engineers share one deployment key, the logs hide who changed the disk rules. Teams also run into trouble when data masking is missing on test volume snapshots. If you clone production disks for testing, masking rewrites emails, phone numbers, and card numbers.
To fix permission risks, split your roles into small, clear pieces. Give the deployment tool permission to manage only the operator and storage class objects. Do not let it read secret data from other app namespaces.
Scope the cloud node role so it only touches disks with specific cluster tags. Lock down the network path between your continuous delivery runner and the cluster API. Use private endpoints so traffic never crosses the public internet during a deployment.
Managing stateful updates and day two operations
Day two storage changes need careful planning to avoid data loss. Some Kubernetes storage fields cannot change after you create the object. If you edit an immutable field in code, the tool tries to replace the resource.
Replacing a live storage resource can detach disks from running database pods. Always run a preview step in your pipeline before you apply changes. Check the plan to make sure the tool updates objects in place without deleting them.
Keep your cluster build code separate from your app storage code. Put the base cluster and storage operator in one stack. Put app volume claims and backup schedules in a second stack. This split stops an app update from breaking the core storage engine.
Check database and API queries on the wire
Identity tools, roles, and network rules decide who opens a session. Setup alone cannot check what each query does or mask sensitive values in a response once a session starts. When workflows touch Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, or internal HTTP APIs, hoop.dev runs beside those services as an open-source proxy, a sidecar for your Postgres or API. It inspects requests coming in and results going back on the wire.
Your login details and client tools stay as they are while hoop.dev guardrails refuse bad deletes or drops before they run. On responses, hoop.dev data masking rewrites matched sensitive values in memory. Furthermore, hoop.dev holds SOC 2 Type II, is MIT licensed, and writes every query and decision to an audit trail that generates evidence for HIPAA, GDPR, and PCI DSS. See the source on GitHub.
Frequently asked questions
How does Pulumi install Portworx on a Kubernetes cluster?
It deploys the storage operator through standard Kubernetes resources or Helm charts. Once the operator runs, the code applies a custom cluster spec to start the storage nodes.
What happens if Pulumi tries to delete a Portworx volume in use?
Kubernetes blocks the deletion until the pod stops using the volume claim. Your deployment pipeline will hang and time out until the pod releases the disk.
Should we store Portworx license keys in plain Pulumi files?
No, never store plain keys in your code files. Use the built-in secret encryption in your state tool so keys stay safe at rest.
Related guides
In this post