Infrastructure as Code SDK for Python. Current version: 3.227.0 (Mar 2026). Requires Pulumi CLI installed separately — 'pip install pulumi' alone does nothing useful. All resource properties return Output[T] not plain values — cannot use them directly as strings/ints. Must use .apply() or Output.all() to work with output values. pulumi.export() must be at top level, not inside apply(). CLI and SDK versions should be kept in sync.
pip install pulumiVerified import paths — ran on the pinned version, not inferred.
Pulumi Python — S3 bucket and security group with stack exports.
Install CLI: curl -fsSL https://get.pulumi.com | sh. Then: pulumi new <template> && pulumi up.
Use .apply(lambda val: ...) to access the inner value. Or use Output.all() to combine multiple outputs.
Call pulumi.export('key', output) at the top level — not inside apply(), functions, or conditionals.Keep pulumi CLI and pip install pulumi at the same major.minor version. Check: pulumi version && pip show pulumi.
pip install pulumi pulumi-aws for AWS. pip install pulumi pulumi-azure-native for Azure.
Don't use hasattr() on Pulumi resources. Check the resource type's documented properties instead.
Always use the Pulumi CLI: pulumi up, pulumi preview, pulumi destroy.