I am deploying a new rails 7 app on cpanel whm OS is centos 7, I am following the following guide.
https://www.thecpaneladmin.com/installing-ruby-on-rails-passenger-cpanel-server/
Points I would like to add:
There is no ruby on rails button in cpanel even though enabled from WHM
I have tried with the way in which we have to register application but It doesn't work
Currently I have created a new project inside public_html according to link the I mentioned earlier and did the configurations according to it but if I try mydomain.com It open index.html file inside public_html
Solution was to use passenger gem inside the project that is to be deployed
Passenger Documentation for details: https://www.phusionpassenger.com/library/walkthroughs/deploy/ruby/ownserver/apache/oss/el7/deploy_app.html#rails_install-app-dependencies
Related
So lately, I offer myself a Mac Mini which I want to use as a server (Websites, caching, Xcode Server (which is not working), VPN (which is not working), and stuff). Currently it is running macOS Sierra (10.12.4) with Server.app (5.3) installed. I've successfully enabled Websites & DNS service so my server is accessible from the outside. I have a trusted and valid SSL certificate.
The problem is...
...I don't know how to setup the server to be a production server for Ruby On Rails.
Want I want
To host a web app using Ruby On Rails on macOS server (www.example.com)
To know how to setup the server app to serve a web app
To host a Git repository for the web app code
I looked at the settings for Websites service in the Server app but I didn't find any options for other than PHP and Python.
What I know
My MacBook is already setup with Ruby 2.4 and Rails 5.0. I know how to install Rails for development purpose
Even if it's not straight-forward, post any help you have.
One of my guesses is that I could forward the port opened for the website without specifying a folder where the files are in the Server app.
I'd be pleased of you inlight in some way to achieve my goal.
I am pretty sure that you don't want to actually run production off of your mac mini. That said once you have your rails app running you can run rails s to run your server locally. If you want a production site you should look into either heroku or AWS elastic beanstalk for deployment.
I am using:
Ubuntu 12.04
JRuby 1.7.2
Rails 3.2.12
Tomcat 7.0.26
I have successfully run my application using
rails server
command and work with my demo application on 127.0.0.1:3000 .
I have installed warble gem and using
warble
in my application directory generates .war file which I have deployed. Unfortunately, when I try to reach my application using 127.0.0.1:8080/depot/ I get the following error:
org.jruby.exceptions.RaiseException: (NameError) cannot load Java
class com.ibm.db2.jcc.DB2Driver at
org.jruby.javasupport.JavaClass.for_name(org/jruby/javasupport/JavaClass.java:1227)
...................
So, I believe the application is not able to find the specified driver but how I am supposed to deploy it?
Also, using Tomcat in this way, will be my application visible from remote PCs?
Have you installed the db2 database drivers into the Tomcat shared resources folder? Or are they deployed as part of the .war ?
The simple answer is no. 127.0.0.1 always routes to localhost; You would need to define a new virtualhost in the TomCat configuration in order to expose your application to the outside world.
I'm very new to Ruby environment ..
I want to run my Ruby on rails Application in apache in xampp on windows xp rather than WeBrick server which is in-built for ruby on rails...
I tried it by adding Virtual host in apache- http.conf file
When i run my application i'm able to see "Welcome Abroad"....
But when i click on "About your application’s environment"
it was showing error like the following
Object not found!
The requested URL was not found on this server. The link on the referring page seems to be wrong or outdated. Please inform the author of that page about the error.
If you think this is a server error, please contact the webmaster.
Error 404
localhost
9/9/2011 10:47:31 AM
Apache/2.2.17 (Win32) mod_ssl/2.2.17 OpenSSL/0.9.8o PHP/5.3.4 mod_perl/2.0.4 Perl/v5.10.1
To deploy your app with apache you need to use phusion passenger http://www.modrails.com
There are plenty of how-to's around the web and the documentation is good enough to get the service running.
This means your Ruby on Rails server is NOT running.
You need to run your server first.
I made a batch file, start-server.bat which contains
d:
cd "D:\Ruby\Web\rails1"
"C:\RailsInstaller\Ruby1.9.3\bin\ruby.exe" script\rails server
then check the PORT number of the server that is running,
So since the port on the screenshot says 10524, you can run it on
http://localhost:10524/
I've been trying to set up a web server using EC2 on Amazon web services.
Using the appstack-nginx-passenger-ree AMI, I tried to set up the server.
I put my ruby files in /opt/sites and I installed passenger and apache2-dev & apace2-mpm-fork.
I had to set up the apache config file.
Afterwards what should I do?
How do I set the path file of the ruby files and deploy them?
How can I start up the server and be able to look at it?
You should make sure you start up apache (which should show you a default welcome page on your the IP of you box (if you have opened up the firewall)), then setup the path to your ruby project in your httpd.conf file.
Here's a guide that might help you out
Paul, your link is broken, the corrected link for the guide is this Setting up Rails 3 on Amazon EC2 instance
I am developing a Rails 3 application and I have installed Capistrano on the client side and Passenger with Apache 2 on the server side.
I make a deployment and the files are sent to a folder called u/apps/.
But when I visit the IP address I am currently using I only get to an empty folder, how do I configure Apache to look for my app in the current folder? So that I only need to visit my IP/domain to see my app?
I have done this using Rails 2.x but I think for Rails 3 also pretty much the same thing. For this you need to use Passenger and then configure Apache.
Following are some useful resources
http://www.modrails.com/install.html
http://railscasts.com/episodes/122-passenger-in-development
If you browse to your URL and you see an apache files/folders list that means that passenger is not triggered for that location...
Test your server environment by running a mongrel/thin in your application folder and see that your application runs correctly. After that, look at your Apache configuration (see Passenger docs).