First, the guide is awesome. Time very well spent. Can’t say enough good about it.
In working through the guide, I keep getting SST to the state where resources deployed in the past are blocking current deploys. Right now, I’ve got the Notes S3 upload bucket and Dynamo table blocking a npx sst start
.
Doing a npx sst remove
doesn’t help. If I delete the bucket and Dynamo table, the deploy will succeed, but I’m wondering what I’m doing that is causing this, because I don’t want it happening in production.
Is there something I should be doing when I’m finished a development session? I’m just using Ctrl-C to interrupt npx sst start
. Is there something else?
The thing you’ll want to look in to is Removal Policies. Some of the resources are defaulted to keep the resource around after the application is pulled down (npx sst remove
) - it’s mostly resources that contain data a la DynamoDB, S3, RDS, etc… You can configure the removal policy in your resource definition.
In order to get unblocked by what’s currently there you either need to:
a) Rename your resources.
b) Delete the resources manually from the AWS Console.
Thanks a bunch. I’ll look into Removal Policies.
Yes, I’ve just been deleting resources from the AWS Console, but I’m trying to avoid getting into that state in the first place.
It sure doesn’t look like terminating an sst start
removes any resources. So it seems like an sst remove
should be executed before, say, going home for the weekend, no?