Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bundle server code with webpack #578

Merged
merged 7 commits into from
Sep 9, 2018

Conversation

forabi
Copy link
Contributor

@forabi forabi commented Sep 8, 2018

This splits the deployment package into 2 ZIP files (one for each function), each is around ~7MB. The package size for serveLogEndpoint could be reduced even further if there was an easy way to make serverless-webpack respect the per-function include option of Serverless.

Fixes #569

@forabi forabi merged commit 3b348b4 into hollowverse-archive:beta Sep 9, 2018
Copy link
Contributor

@wholesomedev wholesomedev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

webpack:
packager: 'yarn'
webpackConfig: ./src/webpack/webpack.config.server.js
includeModules: true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If webpack builds a single JS bundle, that includes all the dependencies, why do you need to includeModules?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because there are still some packages not bundled with webpack due to incompatibilities. Those are defined in the externals field of the webpack config.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants