Clivern / Beaver

💨 A real time messaging system to build a scalable in-app notifications, multiplayer games, chat apps in web and mobile apps.
https://clivern.github.io/Beaver/
MIT License
1.54k stars 82 forks source link

Suggestion to generate smaller images #53

Closed renatosuero closed 5 years ago

renatosuero commented 5 years ago

I checked the Dockerfile and I'd like to do some suggestions to you(of course, I can do the changes and send a PR, if you are interested).

beaver-alpine -> I changed FROM golang:1.11.1 to FROM golang:1.11-alpine, it need to add git and CGO_ENABLED=0. beaver-builder ->I used the Dockerfile to build the image, but I used alpine(it could be scratch) to run the project. As you can see in the screenshot, we can create smaller images.

screen shot 2019-01-24 at 11 24 18
Clivern commented 5 years ago

Your are right and that is already part of the enhancements PR, Please check here https://github.com/Clivern/Beaver/pull/48/files. It will use golang:1.11.1 as builder and use alpine:3.8 to run go bin it can be even scratch but alpine is better

I think i will split that PR since probably it will take time to come with all the feature i planned to add and incrementally push them to master.

Please feel free to review that PR and all comments are welcome

renatosuero commented 5 years ago

Sorry my mistake, I didn't check the PR :(