Why do I see page with a plain “Hello” and title “Example” after Rails Droplet in DigitalOcean installation?

I established DigitalOcean Droplet with Rails+Nginx+Puma (Rails version: 5.2.1, Ruby version: 2.5.1 (x86_64-linux), Ubuntu 18.04) and as a result I see popular “Yay! You’re on Rails!”. So I added new controller and view, updated routes.rb, precompiled assets, updated view to see the simpliest “Welcome” which I wrote inside a view, restarted server (rails.service). But as a result I see “not-my” page with a title “Example” and content of this page is a plain standard text “Hello”. And I cannot execute seeing “my” pages (neither in development nor production environment). This occurs only for routes defined in routes.rb. When I set this new view as the root route then I see this plain “Hello” text on a page also when I get a homepage (my_IP_address). When I turn off the root route then it’s “Yay! You’re on Rails!”. There are no errors in server log and access log show is ok too (codes 200). What am I missing? What should I do to see “my” pages?

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer