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

Enhancement/Turn dockerfile into a multi-stage build #118

Merged

Conversation

@c-w
Copy link
Member

c-w commented Mar 22, 2019

Using a multi-stage build reduces the image size from 1.23GB to 331MB which means that any node running doccano can now start-up faster.

Additionally, the multi-stage build means that we no longer include in the production image development tools like node (now excluded since it's only installed in the builder layer) or gcc (now excluded since the production layer is based on python-slim) which reduces the attack surface of the image.

Using a multi-stage build reduces the image size from 1.23GB to 331MB
which means that any node running doccano can now start-up faster.
Additionally, the multi-stage build means that we no longer include
development tools like node or gcc in the production image which reduces
the attack surface of the image.
@c-w c-w force-pushed the CatalystCode:enhancement/reduce-docker-image-size branch from b25e1da to c248e34 Mar 22, 2019
@Hironsan Hironsan merged commit aa7bb4f into doccano:master Mar 25, 2019
2 checks passed
2 checks passed
Travis CI - Pull Request Build Passed
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@Hironsan

This comment has been minimized.

Copy link
Member

Hironsan commented Mar 25, 2019

Awesome!

@c-w c-w deleted the CatalystCode:enhancement/reduce-docker-image-size branch Mar 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.