salmon-account-74572
03/23/2020, 10:36 PMpulumi config set ...
and then access them in my TypeScript code. In the past, when only dealing with AWS-specific details, I'd use this code:
const config = new pulumi.Config("aws");
const configRegion = config.require("region");
Now, though, I'm trying access both AWS-specific details and non-AWS specific information. I would've thought this would work, but it doesn't:
const config = new pulumi.Config();
const configRegion = config.require("aws:region");
Instead, I keep getting prompted to set configuration value <stack-name>:aws:region
. I've set the region using pulumi config set aws:region us-west-2
and pulumi config set <stack-name>:aws:region us-west-2
, both to no avail. (The latter option doesn't work, even though that's what pulumi preview
references as an error.)
What am I missing?gentle-diamond-70147
03/23/2020, 11:13 PMaws
context and for non-AWS use the "default". e.g.
const awsConfig = new pulumi.Config("aws");
const configRegion = awsConfig.require("region");
const config = new pulumi.Config();
const otherValue = config.require("otherValue");
salmon-account-74572
03/23/2020, 11:16 PM