Digital Ocean's RoR Image setting up new project correctly?
Hello, I’m new to Ruby on Rails. I’ve recently created a droplet using Digital Ocean’s one click Ruby on Rails on Ubuntu 14.04 (Nginx + Unicorn). My goal is create a new RoR project in the home directory and change the root path from the default rails directory to my new directory.
I then created a new project called blog using mysql database.
I modified /etc/nginx/sites-enabled/default and changed root to /home/blog
Next, I modified /etc/default/unicorn and changed APP_ROOT= to /home/blog
Next, I modified /home/unicorn/unicorn.conf working_directory to “/home/blog”
Afterwards, I bundle install blog directory and restarted unicorn and nginx services.
When I go to my website, it redirects to /blog/public/500.html
I followed a steps on some tutorials to created a welcome index page using ‘rails generate controller welcome index’ command and uncommenting 'root “welcome#index”’ in blog’s routes file.
After I restart unicorn and nginx services, I expect to see a welcome index page, but I still the 500.html page. Where did I go wrong?
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.