Pavan Kumar
11/10/2021, 11:03 AMCongnito instance using Auth. But for the production stage cognito instance has already been created manually. What is the best way to create Auth instance such that, in other stage , sst manages creation of cognito but in production stage it uses existing cognito instance. Even better if there is a way to include existing cognito as if it was created using SST, so that infra code is uniform across all the stages.JP (junaway)
11/10/2021, 11:36 AMapp.stage and or app.IS_LOCAL.
Another approach is to extract stateful resources, like your Cognito pool, into another stack. In this case, you would either (1) conditionally-create the stack using the same technique as before or (2) use SSM or env vars to shared information across stacks, like pool IDs and such.Pavan Kumar
11/10/2021, 1:43 PMPavan Kumar
11/10/2021, 3:25 PMcongnito is not supported for importing existing resource