Introducing envVarMappings for Provider Credentials
Blog post from Pulumi
Pulumi v3.220.0 introduces a new resource option called envVarMappings, which addresses the challenge of running multiple providers with different credentials in the same program by allowing users to remap provider environment variables to custom keys. This feature enables developers to set authentication values either as secrets in the Pulumi.yaml config or through terminal environment variables, facilitating seamless integration in CI environments without writing sensitive data to state. By allowing the remapping of environment variable keys on providers, users can now manage multiple providers targeting different accounts without the need for hard-coded environment variable names, thereby reducing the potential for noisy diffs during token rotations and enhancing flexibility in configuration management.