FAQ Database Discussion Community


Passenger could not be initialized because of this error: Option 'agents_dir' missing in file - Rails 4 + Passenger deployment

ruby-on-rails,apache,ruby-on-rails-4,deployment,passenger
I have been banging my head against a door trying to deploy a Rails 4 app on Ubuntu 14 + Apache2 + Passenger. I seemed to have made some progress: passenger is installed properly with the proper apache modules, my apache conf files are set up, everything is restarted, etc.....

Rails 4 Subdomain on production (Nginx + Passenger)

ruby-on-rails,ruby-on-rails-4,nginx,passenger
I've setup 1 apps for ex, example.com with devise auth on it. So when user signup, it will automatically create the subdomain for that user, for ex: user1.example.com where it will showing user profile, (as i follow here: https://railsapps.github.io/tutorial-rails-subdomains.html) In my development env which is i use pow, everything work...

Django file upload took forever with Phusion Passenger

django,apache,file-upload,passenger
I have a Django app deployed using Passenger (I did not choose mod_wsgi because mod_passenger is already there and being used). When I uploaded an MP3 file (900 kB), Google Chrome displays upload % which reached 100% pretty fast but then it took forever for the resulting page. The database...

Cannot start redmine: error 500

ruby-on-rails,rvm,passenger,redmine
I'm trying to deploy Redmine on my RHEL 6 server. I've checkout the code from SVN and installed all the gems bundled with it. Then I've installed the passenger module for Apache with passenger-install-apache2-module and I obtained all green checks at the end of compilation. So, here are my configuration:...

How do I get Phusion Passenger to recognize the correct version of bundler?

ruby-on-rails,ruby,passenger,bundler,gemfile
First of all, I am a programming newbie and even more recent Ruby/Rails newbie. I have a site that I am trying to upload (http://suzyogi.com). Most of the pages are just HTML and CSS with a bit of jQuery, but I wanted to include a blog, so I built it...

CVE-2015-3225 rack and passenger

ruby-on-rails,passenger
Following CVE-2015-3225, I want to update the rack version of some apps that are hosted via passenger in production. However, I am not sure what the relationship is between passenger and rack. Do I need to update the version of rack passenger is using, or the rack version specified in...

Deploy Rails app on Passenger Issue

ruby-on-rails,ruby,apache,passenger
I´m trying to deploy a new rails app on pushion passenger integrate as Apache Mod and always get the following error: Could not find byebug-4.0.5 in any of the sources. If a comment in Gemfile.lock this dependency a get another error message for coffe-script. And no mather what dependency I...

Installing Passenger & Nginx using Vagrant shell script

shell,nginx,vagrant,passenger
This is my first post to SO so I hope I'm asking this correctly. I wrote a shell script to automate the installation of Passenger & Nginx (along with some other components) without any user input on a Vagrant VM running Ubuntu 14.04. It works fine using the following: echo...

'ruby uuid' file or directory not found error using apache and sso

ruby-on-rails,ruby,apache,single-sign-on,passenger
I am trying to deploy a rails application using apache and passenger. I have also integrated it with Okta for authentication. Though everything seems to be working fine after bypassing the authentication or by using thin/webrick server. I am getting the following error in my error logs if I use...

502 Bad gateway error/NameError in Rack application for sinatra app on nginx, passenger in a docker container

nginx,sinatra,docker,passenger
I am starting with docker (1.3.2) and I am trying to get an example working with nginx, passenger and sinatra. Nginx and passenger seem to work. However, I do not get my sinatra app to run. curl localhost gives a 502 bad gateway error and the same when I try...

ssl passenger nginx rails 4 routing combine wrong port with https

ruby-on-rails-4,ssl,nginx,passenger
I folowed the rails tutorial org tuto and made a web site Installed passenger, nginx. Works perfectly on prod env on heroku=> http://klat.herokuapp.com/ (app not finished but still better than nothing) Here i use the => config.force_ssl = true (only for heroku) my routes from routes.rb => Rails.application.routes.draw do get...

Access rails development server from another computer [closed]

ruby-on-rails,passenger,server
I have a laptop installed with archlinux and an iMac. I want to do my rails development on the laptop which has no GUI, and to be able to look at the web app on the iMac. How do I access Phusion passenger server with my rails app that is...

Capistrano and XSendFile configuration

ruby-on-rails,apache,capistrano,passenger,x-sendfile
I am trying to configure Rails production server with Apache 2.2, Passenger 4.0.59 and XSendFile 0.12. Application is deployed via Capistrano. Deployed application produces (maybe large) PDF to #{Rails.root}/tmp and serves this file using send_file. The problem is that Capistrano uses symlinks to point to currently deployed version of application....

Rails 4.2 ActiveJob: Every adapter results in PhusionPassenger error: Could not find [gem] in any of the sources (Bundler::GemNotFound)

ruby-on-rails,ruby,ruby-on-rails-4,passenger,rails-activejob
I'm trying to implement asynchronous email processing with Rails 4.2's ActiveJob API. So far I've tried using two of the supported adapters: Sucker Punch and Delayed Job, and I get the same problem with each. Things seem to work correctly in development. However, after deploying to the staging server and...

AWS Beanstalk - Passenger Standalone not serving web pages after Rails 4.2.1 migration

ruby-on-rails,ruby-on-rails-4,amazon-web-services,passenger,elastic-beanstalk
My Rails 3.2.21 app was running fine on AWS Beanstalk under Passenger Standalone 4.0.53. I migrated the app to Rails 4.2.1 and got it passing all tests on my local development machine (Ubuntu, WEBrick). I deployed it to Beanstalk (aws.push), the deploy succeeds (copied from /ondeck to /current) and: nothing....

Rails not working with apache and passenger

ruby-on-rails,apache,passenger
Listen 81 <VirtualHost 192.168.1.43:81> ServerName localhost ServerAlias www.example.com ServerAdmin [email protected] DocumentRoot /home/eze/Appp/public RailsEnv development ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined <Directory "/home/eze/Appp/public"> Options FollowSymLinks Require all granted </Directory> </VirtualHost> Hi Iam having the following error when I try to use my rails app from apache and passenger, I am new...

Unable to send data from rails app in aws to android app

android,ruby-on-rails,amazon-web-services,amazon-ec2,passenger
I have built a rails app which interacts with an android application. Sending and receiving data from android on localhost is working flawlessly. But when I upload to an AWS EC2 instance, I'm only able to send data from android to server not the other way around. I am using...

How to set up two domains to point at the same app with Passenger but with different Rails functionality?

ruby-on-rails,ruby,apache,ruby-on-rails-4,passenger
I have two domains on Apache: domain1.tld & domain2.tld Presently I have domain1.tld working perfectly with Passenger, but I also need domain2.tld to point to this same application, but when it reaches this second domain, it will have different functionality (ie, call a different controller and have some different routes)...

Performance difference between Passanger and Mongrel web server

ruby,ruby-on-rails-3,passenger,mongrel
I am working on a Rails 3 project which was using Mongrel as web server but now I changed it to Passenger web server. And because of this my application respond very slowly. So I want to know about the performance difference between these two server in production environment.

Can't seem to get Bundler to run properly on Rails App server using Capistrano to deploy

ruby-on-rails,ruby,passenger,bundler,capistrano3
I've been using Rails for a couple of months now and made a small app that I'm trying to deploy with Capistrano. The problem is that when I run $ cap production deploy the deployment appears to run correctly except for the following 3 errors: DEBUG [764d7f01] Running /usr/bin/env [...

installing ruby on rails on passenger dosn't work

ruby-on-rails,ruby,ruby-on-rails-4,passenger
is there a good and simple installation guide how to install phusion passenger on my apache2 and then install ruby on rails? I'm using debian 7 i've done point 2.31 and 2.3.2 https://www.phusionpassenger.com/documentation/Users%20guide%20Apache.html#rubygems_generic_install then I tried this: $ gem install rails and got this error ...

Enable DELETE method with nginx, passenger and Rails

ruby-on-rails,nginx,passenger
I try to deploy a rails application with passenger and nginx. All is working fine but when i want to send a DELETE request like this for example: <%= link_to "Sign out", sign_out_path, method: :delete %> In developpement it works fine but in production with nginx it's doing a GET...

Creating a symlink for Ruby while using RVM

ruby-on-rails,ruby,ubuntu,nginx,passenger
I am following this https://www.digitalocean.com/community/tutorials/how-to-deploy-a-rails-app-with-passenger-and-nginx-on-ubuntu-14-04 But i have installed Ruby using RVM as its easy to maintain ruby. I am at the step to create a symlink for ruby which under this guide it says sudo rm /usr/bin/ruby sudo ln -s /usr/local/bin/ruby /usr/bin/ruby But since i have used RVM and...

javascript_include_tag file is missing on the production environment ( 404 )

javascript,ruby-on-rails,nginx,passenger
On the development environment (with therubyracer) all works great. Now I set nginx + passenger to run my rails app for the production environment. All works fine except one (slides_index.js) file for which I get 404. That file contains jQuery code which has to be run just on one page....

Passenger install script reports success but fails to install Nginx

ruby-on-rails,ubuntu,nginx,passenger
I'm attempting to install Rails + Passenger Phusion + Nginx on my Ubuntu 14.04 headless server. I have been following this tutorial here. All was going well until the section where you hand over to passenger Phusion to install Nginx using the command rvmsudo passenger-install-nginx-module. I select the first option...

passenger issue with cloud66 deploy

ruby-on-rails,nginx,passenger,cloud66
when i deployed using cloud66 I got this: First time this happened: We're sorry, but something went wrong. We've been notified about this issue and we'll take a look at it shortly. The Phusion Passenger application server encountered an error while starting your web application. Because you are running this...

Apache Passenger handle 'www' in url

apache,passenger
I've an application deployed to EC2 using passenger and apache2. I've registered a domain (not with AWS) and have two 'A' records pointing to my instance's elastic IP appname.com. *.appname.com. In my apache2.conf file (below), I've got ServerName appname.com The application is working perfectly when you type appname.com into a...

Does Phusion Passenger automatically precompile assets after restarting?

ruby-on-rails,asset-pipeline,passenger
Via git, I downloaded the latest version of my web-app to our server. I did a touch tmp/restart.txt but this didn't precompile my assets. I did a rake assets:clobber assets:precompile and this refreshed my assets. Is Passenger supposed to refresh my asset pipeline automatically? If it is, what are some...

Passenger Still Runs in Production Despite Everything Seeming to Be Correct?

ruby-on-rails,docker,passenger
I'm running Passenger inside of the Phusion provided Docker container (https://github.com/phusion/passenger-docker), and have set my Rails environment to a dev setting using the following: docker run -rm -p 80:80 -e RAILS_ENV=development <image_name> However, Passenger continues to only run in production mode. What would cause this?...

Passenger repository certificate verification failed

ruby-on-rails,linux,ubuntu,debian,passenger
I want to install Passenger server on my virtual machine, so I do the following: sudo sh -c "echo 'deb https://oss-binaries.phusionpassenger.com/apt/passenger trusty main' >> /etc/apt/sources.list.d/passenger.list" sudo chown root: /etc/apt/sources.list.d/passenger.list sudo chmod 600 /etc/apt/sources.list.d/passenger.list But after I update sudo apt-get update I get this errors: Err https://oss-binaries.phusionpassenger.com trusty/main amd64 Packages server...

Adding second virtual host with different Ruby and Passanger version

ruby-on-rails,ruby,apache,deployment,passenger
I have main Rails app working on system Ruby and Passanger. Following virtual host works just fine: <VirtualHost x.x.x.x:80> ServerName domain.com DocumentRoot /home/john/apps/main_app/public PassengerRoot /var/lib/gems/1.9.1/gems/passenger-4.0.29 PassengerRuby /usr/bin/ruby <Directory /home/deploy/apps/main_app/public> PassengerEnabled On AllowOverride All Require all granted Options -MultiViews </Directory> </VirtualHost> Now I want to add second virtual host for my...

Phusion Messenger virtual host

ruby,apache,passenger
I am trying to run a ruby application server with phusion passenger. The problem is that the application is hosted on an apache server that hosts other websites too. So I tried to implement virtualhost. Now for some reason I can't reach my application. The DNS does redirect the queries,...

nginx, passenger only showing root page, all other routes fail

ruby,nginx,passenger
Nginx + passenger is only showing the root page / path, all other routes fail with 404 Not Found. I know nginx and passenger must be running to correctly bring up the root path. Here's the entry for sites-available: server { listen 80; server_name staging.redacted.com; # Replace this with your...

Error in starting Rails Passenger App

ruby-on-rails,passenger
I changed ruby version to 2.1.5 with RVM, configured 4 rails App with Apache, but I can't start them with Passenger. So I got this error everytime. App 8612 stderr: Cannot execute "/root/.rvm/gems/ruby-2.1.5/gems/passenger-5.0.8/buildout/support-binaries/PassengerAgent": Permission denied (errno=13) [ 2015-06-01 20:11:43.2847 8422/7f244835b700 App/Implementation.cpp:287 ]: Could not spawn process for application /var/www/example: An...

AWS Elastic Beanstalk Error - Passenger

ruby-on-rails,amazon-web-services,passenger,elastic-beanstalk
I've tried various solutions that are intuitive and then have tried the solutions that have apparently helped others. I've spun up and terminated my Rails 4 app about 10 times. So...I thought I'd turn here to see if anyone knew an answer. Here is the log file: [ 2015-03-06 06:12:27.0070...

Increasing heap size for JRuby using jruby_opts

ruby-on-rails,rvm,passenger,jruby,jrubyonrails
I am having issues with increasing the heap size for JRuby. The application is running Phusion Passenger and I installed JRuby using RVM. I have tried export JRUBY_OPTS="-J-Xmx1024m" But it doesn't change the heap size. I tried jruby -J-Xmx1024m but it doesn't return and gets stuck. I am not sure...

Passenger (Apache) on EC2 not loading Rails application when arrive via DNS

ruby-on-rails,apache,amazon-ec2,dns,passenger
This is driving me nuts. Hopefully someone can help I've deployed a Rails app on an EC2 instance (Ubuntu) using Apache and Passenger. Here's my Apache configuration on the EC2 instance /etc/apache2/apache2.conf <VirtualHost *:80> ServerName ec2-52-16-160-160.eu-west-1.compute.amazonaws.com # !!! Be sure to point DocumentRoot to 'public'! DocumentRoot /home/ubuntu/workspace/intellitute/public ErrorLog /home/ubuntu/workspace/intellitute/log/error.log RailsEnv...

Can't make passenger (for rails) running my apps in production mode

ruby-on-rails,nginx,passenger
First of all: the versions! Rails 4 Passenger: don't know but the last one that I directly compiled on the server. Nginx: last one also. So, my problem is: I am trying to make a rails app running in production with nginx and passenger but I did not succeed until...

Passenger use wrong Ruby version

ruby-on-rails,ruby,nginx,passenger
I installed Ruby 2.1.2 via rvm install 2.1.2, but Passenger uses 1.9.3 where my gems aren't available. After I found the error, I tried to change the passenger_ruby to /usr/local/rvm/gems/ruby-2.1.2 but I got this error: App 30033 stderr: *** ERROR ***: Cannot execute /usr/local/rvm/gems/ruby-2.2.2: Permission denied (13) so I switched...

How to run rails2 app on passenger and apache2 in centos [closed]

ruby,passenger,ruby-on-rails-2
I have an old Rails 2.0.1/Ruby 1.8.7 app it had run in a production environment on centos 6 using thin and appcahe2 server.But i need to run on Passenger and Apache2 server,is there any possibilities to run on it..? Thanks for Your Help.......

Passenger 5.0 with legacy Rails 2.3 app won't boot

ruby-on-rails,apache,passenger
Recently updated Passenger from 4.x to 5.0.7 on my Ubuntu server. Sadly, this broke one of my older application still running Rails 2.3.15, even though Passenger claims to support >= Rails 2.3.x in its new 5.x versions. According to the new Passenger 5.0 documentation I had to create a config.ru...

Only root route works in Sinatra with Passenger/Apache

apache,.htaccess,sinatra,passenger
I have a sinatra app running with Apache/Passenger in a subfolder with the following in an .htaccess file <IfModule mod_passenger.c> Options -MultiViews Allow from all PassengerResolveSymlinksInDocumentRoot on RackEnv development RackBaseURI /myapp PassengerAppRoot /home/username/myapp SetEnv GEM_HOME /mypath/ruby/gems </IfModule> and my Sinatra app has two routes get '/' do 'Root Request' end...

Why I must install gems manually after deploy using Capistrano

ruby-on-rails,ruby,nginx,passenger
Ubuntu server, production mode. Install RVM with ruby (2.0) and Bundler. Capfile: # Load DSL and Setup Up Stages require 'capistrano/setup' # Includes default deployment tasks require 'capistrano/deploy' # Includes tasks from other gems included in your Gemfile # # For documentation on these, see for example: # # https://github.com/capistrano/rvm...

nginx - how to create rails app without app name in domain

ruby-on-rails,ruby-on-rails-4,nginx,passenger
I'm using nginx with passenger and I wanted to ask, how to create rails app, without showing app name in domain. Currently I know how to setup nginx configuration with domain like this: domain.com/app_name and in the routes file when I create root 'welcome#index' I still have to type domain.com/app_name...

How does Phusion Passenger respect gemfiles?

ruby-on-rails,passenger
I'm wondering how it's possible to host multiple projects using different versions of Ruby and completely different gemsets. When I'm developing on my machine I use Bundler and chruby. But when serving production environment, can I use Bundler and chruby with Passenger either? How does that work?

Disconnecting client with error: client socket write error: Broken pipe - passenger 5.0.2

ruby-on-rails,passenger
When I start Phusion Passenger Standalone web server (version 5.0.2), I see the following error in the log (even though everything works fine otherwise): ServerKit/Server.h:892 ]: [Client 1-1] Disconnecting client with error: client socket write error: Broken pipe (errno=32) Any idea what might be causing it? Note: I start the...

Fetch env variables set by shibboleth in phusion passenger rails4

ruby-on-rails-4,passenger,shibboleth
In a rails4.2.0 app, with phusion passenger 5.0.2 under apache-2.2.22 (Debian GNU/Linux) I am not able to fetch environment variables set by mod_shibboleth (2.5.3-0switchaai1). I used to write: request.env["uid"] in shibboleth-protected Locations, but now in request.env I find only "REMOTE_USER". I am sure shibboleth-sp receives and set variables: I can...