8000 GitHub - stevecaldwell77/serverless-bug-2984
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

stevecaldwell77/serverless-bug-2984

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

serverless-bug-2984

This repository contains serverless configuration files that can be used to reproduce the bug described here:

serverless/serverless#2984

Please note that deploying the below services will bill some (very tiny) expenses to your AWS account, the author takes no responsibility for any costs accrued.

Steps to reproduce bug

Initialize:

(cd service1/ && yarn)
(cd service2/ && yarn)

Deploy service1. This service will create an S3 bucket and export its Arn as ServerlessBug2984BucketArn:

(cd service1/ && npx sls deploy)

Deploy service2. This service will use the exported bucket arn from service1 to configure IAM:

(cd service2/ && npx sls deploy)

Now try to remove service1. AWS will not allow you to remove the service1 stack, since service2 is dependent upon it:

(cd service1/ && npx sls remove)

However - THIS IS THE BUG - serverless says that everything was removed correctly:

Serverless: Getting all objects in S3 bucket...
Serverless: Removing objects in S3 bucket...
Serverless: Removing Stack...
Serverless: Checking Stack removal progress...
..
Serverless: Stack removal finished...

You can verify that service1 is still around:

aws cloudformation describe-stacks \
    --stack-name serverless-bug-2984-service1-dev

Note that the stack's StackStatusReason is set to:

Export ServerlessBug2984BucketArn cannot be deleted as it is in use by serverless-bug-2984-service2-dev

Cleanup

To cleanup, just make sure to remove the services in the correct order:

(cd service2/ && npx sls remove)
(cd service1/ && npx sls remove)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published
3030

Packages

No packages published
0