We are using Serverless framework and enabled Serverless dashboard. We refer to Outputs from cloud formation stacks to refer them in a different stack (don’t export them and yet are able to refer to them just fine in other stacks). Started getting the error mentioned only since we enabled Serverless dashboard. Why would that be ? Is there a bug?
We do not unnecessarily want to add export since it has been working without it too.
In stackA : I have
resources:
Outputs:
SnsTopicLambdaNonCriticalAlarmsArn:
Value: !Ref SnsTopicLambdaNonCriticalAlarms
SnsTopicOnboardSystemArn:
Value: !Ref SnsTopicOnboardSystem
This gets references in stackB
custom:
snsOboardSystem:
arn: ${cf:vlncc-resources-sns-${self:provider.stage}.SnsTopicOnboardSystemArn}
We have always been referring it the same way and made no changes. The application still gets deployed in the sandbox env just fine (where serverless dashboard is disabled) . In dev account (where serverless dashboard is enabled), we started getting:
stackB : Trying to request a non exported variable from CloudFormation. Stack name: " stackA " Requested variable: “SnsTopicOnboardSystemArn”.
We have never had to add ’ Export :" in Outputs block
and the cross stack reference still works okay in the sandbox environment. Why would that be?
When deploying in dev , the stackOutput is also display for stackB like it always does.
I know AWS docs say that to reference from a different stack, we need to export: Exporting stack output values - AWS CloudFormation
but how has it been working so far without exporting? Did AWS change anything recently? Is it a bug in Serverless framework? Any resolutions?