In order to run custom script on start up on Linux / Ubuntu system, you can follow these steps:
Create custom file e.g. startup_script in your home folder
Then edit script and enter following
cd /home/SOME_USER/projects/YOUR_AWESOME_FOLDER/; bundle exec rails s
Now make that script executable
chmod +x startup_script
Now open cron tab
And add line at the end of that file that calls your custom created script that should run on startup.
Now each time your server is restarted it will start your applications immediately.