Ross Coundon
05/18/2022, 7:39 PMid
on the stack and when setting a different ID on each stack
I also tried setting the same ID on each stack which I figured would fail and it did. What’s the right way to do this?Robert
05/18/2022, 7:46 PMRoss Coundon
05/18/2022, 7:47 PMRobert
05/18/2022, 7:47 PMRobert
05/18/2022, 7:47 PMRoss Coundon
05/18/2022, 7:48 PMoutaTiME
05/18/2022, 7:48 PM_app_.stack(Stack, { id: 'stack' });
Ross Coundon
05/18/2022, 7:52 PMRoss Coundon
05/18/2022, 7:52 PMRobert
05/18/2022, 7:52 PMRoss Coundon
05/18/2022, 7:53 PMoutaTiME
05/18/2022, 7:55 PMRoss Coundon
05/18/2022, 7:56 PMoutaTiME
05/18/2022, 7:56 PMdev-ambito-dolar-stack
, after dev-ambito-dolar-Stack
outaTiME
05/18/2022, 7:58 PM{ id: 'stack' }
Ross Coundon
05/18/2022, 7:59 PMError: There is already a Construct with name 'x-y-omw-pso-be-sst-stack' in App
outaTiME
05/18/2022, 8:01 PMoutaTiME
05/18/2022, 8:06 PMstackName
(https://docs.serverless-stack.com/constructs/Stack#configuring-stack-name) to leave it the same way it was before, but anyway I think everything this ends up being a workaroundRoss Coundon
05/18/2022, 8:11 PMRoss Coundon
05/18/2022, 8:13 PMoutaTiME
05/18/2022, 8:14 PMRoss Coundon
05/18/2022, 8:15 PMimport { coreResourcesStack } from './core/coreResourcesStack';
import { anotherStack } from './core/anotherStack';
export default function main(app: <http://sst.App|sst.App>): void {
const stackName = `${app.stage}-omw-pso-be-sst-stack`;
app
.stack(coreResourcesStack, { stackName });
.stack(anotherStack, {stackName });
}
Ross Coundon
05/18/2022, 8:17 PMINFO: Deploying 13 stacks...
10.73 s
❌ the-stage-omw-pso-be-sst-stack: Stack [the-stage-omw-pso-be-sst-stack] already exists
outaTiME
05/18/2022, 8:19 PMoutaTiME
05/18/2022, 8:23 PMoutaTiME
05/18/2022, 8:24 PMRoss Coundon
05/18/2022, 8:24 PMRoss Coundon
05/18/2022, 8:44 PMFrank
Frank
thdxr
05/19/2022, 4:47 AMFrank
Frank
Ross Coundon
05/19/2022, 6:37 AM