question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

AWS config in pulumi stack config is no longer respected

See original GitHub issue

Issue

Previously, aws config, including aws:accessKey, aws:region, and aws:secretKey were used from the Pulumi.{stack}.yaml file.
This no longer seems to be the case after what I can only guess was a dependency update.
It was working on Even though pulumi itself was not updated, and no packages in the package.json (using TypeScript) were updated, a CICD build that used to work now no longer works with no changes. And using pulumi refresh no longer works locally.

I can’t recommend or use a tool that can break when I haven’t even updated anything myself.

Error Message

error: Preview failed: unable to discover AWS AccessKeyID and/or SecretAccessKey - see https://pulumi.io/install/aws.html for details on configuration

This page defined how to configure AWS credentials using the AWS CLI, which I am not using.

Config

This is the stack config I am using with sensitive info changed.

config:
  aws:accessKey: <accesskey>
  aws:region: <region>
  aws:secretKey:
    secure: <secret>

References

https://www.pulumi.com/docs/intro/cloud-providers/aws/#configuration

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:5
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

4reactions
ron137commented, Dec 3, 2019

I have the same problem here, “pulumi up” is working fine, but “pulumi refresh” is not.

1reaction
MvnTruongcommented, Nov 1, 2021

Sorry to bring up a 2-year old issue, but I am just encounting this exact issue today where pulumi up works fine, but pulumi refresh does not, with the same error message error: unable to discover AWS AccessKeyID and/or SecretAccessKey - see https://pulumi.io/install/aws.html for details on configuration.

I have two stacks that have identical pulumi.X.yaml files. It can pick up the AWS creds for one stack but not the other

Read more comments on GitHub >

github_iconTop Results From Across the Web

AWS Classic Installation & Configuration - Pulumi
How to set up credentials to use the Pulumi AWS Classic Provider and choose configuration options to tailor the provider to suit your...
Read more >
Intro to Pulumi: Stacks
The operation uses the latest configuration values for the active stack. View stack resources. To view details of the currently selected stack, run...
Read more >
Intro to Pulumi: Configuration
This page provides an overview of how Pulumi manages cloud application configuration settings.
Read more >
Simpler configuration management with project level config
You can still set config for stacks via the pulumi config CLI command, or by editing the Pulumi.<stack>.yaml file. Project level config just ......
Read more >
Before You Begin | AWS - Pulumi
If you have previously installed and configured the AWS CLI, Pulumi will respect and use your configuration settings. If you do not have...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found