https://pulumi.com logo
Title
p

purple-train-14007

04/14/2021, 1:41 AM
Alright, I tried. I dont seem to understand how to output this subnetsId. If someone can help point me in the right direction, I would greatly appreciate it. here is my code so far.
g

gentle-diamond-70147

04/14/2021, 2:09 AM
Which resource are you wanting to output from? Can you share more of your code?
p

purple-train-14007

04/14/2021, 2:10 AM
sure, Im trying to output the SubnetId from the following subnet Im instantiating
g

gentle-diamond-70147

04/14/2021, 2:16 AM
Generally you would have a
subnet
variable on your class that you can reference from your calling code. Here's an example - https://github.com/pulumi/examples/blob/2e9e18b36a9720dd0e691f2bfe883bbfd46bd512/classic-azure-ts-aks-keda/cluster.ts#L20.
p

purple-train-14007

04/14/2021, 2:20 AM
Ah ok so I do this as part of the constructor?
constructor(name: string,
                args: AksClusterArgs,
                opts: pulumi.ComponentResourceOptions = {}) {
        super("examples:keda:AksCluster", name, args, opts);
g

gentle-diamond-70147

04/14/2021, 3:54 PM
You would assign them within the constructor like this. A complete example is here - https://gist.github.com/clstokes/01260b82dca3240c5d4b6207870f2d96.