I needed to run everything, not the rails in the background. An installation screen that makes an additional terminal that is not affected by your ssh connection. sudo apt-get install screen open screen screen then run rails server & .
Press “Crtl + A”, then “D” to exit, and enter screen -r to return to the screen terminal.
source share