-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Completely dockerize Wasp app #172
Comments
I asked for thought of people in our community, and the main feedback was that Dockerized stuff can have performance problems (especially when dealing with filesystem operations on MacOS) and that while they would like everything Dockerized as an option, they don't think it should be the only way of running Wasp locally. Here is link to my message where I started the discussion: https://discord.com/channels/686873244791210014/686873245428875297/821698905477218354 . Below I also copied the discussion, just in case: Discussion on Discord: Click to expandmartinsos — Today at 11:58 Did anybody have experience running frontend or backend dockerized during developmen? My general feeling is that it is recommended as an approach, but that not many people are actually doing it due to being complicated to set up. @mateothegreat you said you are devops ninja :D, what do you think? |
Adding my 2 cents, I think Dockerized stuff has performance problems on OS X, but on Linux it's perfectly fine. This StackOverflow answer explains quite nicely why there is a difference: https://stackoverflow.com/a/55953023/1233908 Personally I'm a Docker convert ever since making the switch from OS X to Linux, but I can understand the frustration there for OS X users. |
Thanks for the comment @cursorial! Yes, on Linux it should be fine, but OSX is tricky. I however read that using docker volumes can help, instead of directly binding the directory from the file system, so maybe that is a way to go about it. Docker volumes should be much more performant, even on OSX, possibly to the level where this is not an issue anymore. |
Just to add to this: using docker volumes is the way to go to persist data on host machine, and they don't have performance issues, I can confirm that after more research / using them. |
Right now, we have Dockerfile for deploying server to production.
We could also use Docker in development though -> both web app and server could be running in their own docker containers, therefore ensuring that they run in exactly the same way for all the developers. This would remove explicit dependency on node, which would become part of the container and therefore part of implementation. So basically, only dependency would be on docker -> if you have docker, you can use wasp.
This does seem to be somewhat tricky, as it can disrupt typical development flow and possibly slow it down. I don't know all the details, but I "heard" it might be tricky getting it to work with the IDE of choice + debugger, possibly also live reloading of web browser.
Also, what if web app requires something installed on the machine, and we don't have it already in the Dockerfile? How would we set that up, enable people to install whatever they need? Maybe they could provide base image to build Dockerfiles from, and we can say it has to be Ubuntu or smth like that?
The text was updated successfully, but these errors were encountered: