Report this

What is the reason for this report?

Ruby code being rendered as html

Posted on June 12, 2014

i followed the guide to load rails on centos to work with passenger. when i go to the ip / site it seem ruby is not being served. All ruby code is rendered as html. Any ideas. This was the case on a ubuntu droplet as well.



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!

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.

If you could provide some more info, we’d be able to help you better. Which guide did you follow? What web server are you using? Apache? Nginx? Could you pastebin your configuration files?

If you’re using Apache on CentOS, check out this tutorial:

https://www.digitalocean.com/community/tutorials/how-to-setup-a-rails-4-app-with-apache-and-passenger-on-centos-6

Hello,

I did use the CentOS guide from the link you provided. Now Apache is not even running. Check all the paths to ruby and added the passenger code to the bottom of the Apache config file, but still no luck.

I did all of this as root. Is that OK? I did notice that when I tried to do a bundle install it says not to do it as a root user. So I added a new user and made it a sudoer. When i try to do a rails new or any command I get a lot of errors!

Sorry I have a windows server now, all this Linux is new to me.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.