orange-kite-80991
11/28/2021, 9:09 PMconfig:
mystackname:SCHEMA:
secure: qqqqq
mystackname:SCHEMA_CONFIG: https://
azure-native:location: westus2
azure-native:subscriptionId: aaaaaa
azure-native:tenantId: bbbbbb
fluid:password:
secure: ccccccc
fluid:username: abc*<http://xyz.com|xyz.com>
A simple require() or get() can access the mystackname: prefixed values. What's the syntax for accessing the other variables?
const config = new pulumi.Config()
const schema = config.require( 'SCHEMA' )
// the following don't work
const location = config.require( 'location' )
const location = config.require( 'azure-native:location' )
const location = config.require( 'azure-native.location' )
little-cartoon-10569
11/28/2021, 9:11 PMconst location = new pulumi.Config('azure-native").require("location");
orange-kite-80991
11/28/2021, 9:28 PMlittle-cartoon-10569
11/28/2021, 9:57 PMIf you are writing code that will be imported into a broader project, such as your own library of components, you should pass your library’s name to the constructor. This string is used as a namespace for all configuration keys. Similarly, if you want to access the config of another library, such as the config for a standard library like aws, you should also pass the library’s name to the constructor.
orange-kite-80991
11/28/2021, 11:18 PMlittle-cartoon-10569
11/28/2021, 11:33 PMnew pulumi.Config('acl')
and new pulumi.Config('firewall')
, and it'll get values from those namespaces. Nothing to do with libraries...orange-kite-80991
11/28/2021, 11:43 PM