I don’t know how you could fix a memory leak, but you can offer one way to hide it and fix it.
If you want to learn Docker, you can keep your development environment inside the Docker container, while accessing the code on your local computer, as well as in the shared folder in Vagrant.
When you launch the Docker container, which starts, you can specify a limit on the amount of memory that the container can use. The rails server process may cause the container to crash and stop, but at least you won’t have to restart your computer.
Perhaps this will give you more opportunities for a deeper resolution of the problem.
Docker Launch Reference , see "Runtime Limits for CPU and Memory".
Matt
source share