This repository was archived by the owner on Jan 28, 2025. It is now read-only.
Bucket existence validated before bucket actually created #119
Open
Description
Howdy! I'm using the assetPrefix
option to let the plugin deploy the assets bucket. However, even after serverless remove
with no pre-existing stack whatsoever, I guess this error:
Serverless Nextjs: Copying next pages to tmp build folder
Serverless Nextjs: Found 2 next page(s)
Serverless Nextjs: Creating compat handler for page: _error.js
Serverless Nextjs: Creating compat handler for page: index.js
Serverless: Packaging service...
Serverless: Excluding development dependencies...
Serverless Nextjs: Cleaning up tmp build folder ...
Serverless Nextjs: Found bucket "serverless-nextjs-richard-dev-assets-bucket" from serverless.yml
Serverless Nextjs: Proxying NextJS assets -> https://s3-us-east-2.amazonaws.com/serverless-nextjs-richard-dev-assets-bucket/_next/{proxy}
Serverless Nextjs: Proxying static files -> https://s3-us-east-2.amazonaws.com/serverless-nextjs-richard-dev-assets-bucket/static/{proxy}
Error --------------------------------------------------
The assets bucket "serverless-nextjs-richard-dev-assets-bucket" does not exist. Create it manually or delete the stack and recreate it.
For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.
Get Support --------------------------------------------
Docs: docs.serverless.com
Bugs: github.com/serverless/serverless/issues
Issues: forum.serverless.com
Your Environment Information ---------------------------
Operating System: win32
Node Version: 10.15.3
Serverless Version: 1.49.0
Enterprise Plugin Version: 1.3.8
Platform SDK Version: 2.1.0
I'm very confused too as I thought serverless-nextjs-plugin
handled this? And it seems like this check is hapenning before serverless actually has a change to deploy the cloudformation stack that creates bucket for the first time?