0
votes
0answers
4 views

File descriptor limit in nginx/Passenger app

We're running a Rails app in Passenger 4.0.45 and nginx 1.6.0 (installed by Passenger installer) running on Ubuntu 14.04. Under heavy load we're getting "Cannot accept client: Too many open files ...
0
votes
0answers
33 views

Accessing an environment variable across nginx w/ Lua and Rails [migrated]

I'm implementing something like this to let one service allow access to separate upstream service in nginx. Briefly: A Rails app sets an HMAC cookie, which is then checked by some Lua code thanks to ...
0
votes
0answers
44 views

Nginx to serve files from multiple locations - resources paths optimization

In my rails 4 app, I have assets pipeline to process my custom js/scss. I also use /vendor/assets/javascripts as a place for 3rd party libs - jquery, requirejs... Those, I don't want to process by ...
0
votes
1answer
47 views

All Passenger processes suddenly hang - backtrace indicates reading POST data?

I've been having problems with my nginx/Passenger server where requests appear to be getting stuck, any subsequent requests don't complete, the queue gets up to its max, and the site starts serving ...
0
votes
0answers
34 views

Restart individual rails apps in nginx+unicorn

I have 15-20 independent rails applications on the same ec2 instance. The rails applications are deployed using apache + passenger with Railsbaseuri. RailsBaseURI /games <Directory ...
3
votes
0answers
59 views

Rails 4 Unicorn+Nginx on Ubuntu 13.04 VPS keeps crashing

I bought a years subscription at bluevm.com (found some coupon code, it was only about $15 for a whole year) to launch my first Rails Production server. I'm running Nginx with Unicorn and MySQL on ...
1
vote
0answers
51 views

Why isn't puma using all of its threads?

I'm using puma and nxinx, and as far as I can tell it is only ever using a single thread even when I start it with the default of 16 threads or more. I've set up a fresh rails app, then gone through ...
0
votes
1answer
61 views

What are the advantages of using dedicated server software over framework built-in servers?

Being a beginner in the web world, I've always used Apache to develop applications in PHP. Getting tired of it, I learned Node.js, Rails and Django -- just to get a taste of each of the most used web ...
1
vote
0answers
247 views

Rails app 502 with AWS Elastic Beanstalk running Puma & Nginx

I've been able to successfully get my application running on Beanstalk with Passenger, however I've had no luck with Puma. Whenever I deploy with to a Puma stack I get 502 Errors, my log files ...
2
votes
1answer
102 views

Passenger Module Fails On AWS Gem With 'Class Variable Name' Error

Opening Disclaimer: I'm all kinds of newb to the technologies involved in this question. But the Googles, she no yield-a the fruit. I'm trying to deploy a Rails app into production. This app works ...
0
votes
0answers
36 views

Application that works on webrick but fails in passenger

I have a ruby on rails application that starts successfully when I execute rails s -p 3000. But when I deploy it on apache or nginx using passenger, I get this result. The deployment instructions ...
2
votes
1answer
69 views

Nginx, setup https

I'm trying to setup https on my ubuntu server with NGINX ver 1.4.7 and Phusion Passenger 4.0.41. I created .key and .csr using these two commands sudo openssl genrsa -des3 -out server.key 2048 sudo ...
0
votes
0answers
59 views

NginX configuration to prevent “Slow HTTP Denial of Service”

I'm trying to configure NginX (in combination with Passenger and Rails) to prevent "Slow HTTP Denial of Service". What I'm trying to do to prevent it, is limiting the amount of requests per ...
0
votes
1answer
395 views

“768 worker_connections are not enough” error after a fresh installation of nginx and ROR

I have a fresh installation of nginx and ruby on rails. But it gives me a '500 Internal Server Error' while testing. The error.log for my app has the following: 2014/05/01 17:27:15 [alert] 1423#0: ...
0
votes
1answer
67 views

Trouble setting up Ruby with Nginx on CentOS 6.5

Following the instructions here: https://www.digitalocean.com/community/articles/how-to-deploy-rails-apps-using-passenger-with-nginx-on-centos-6-5 I get to the point of "Use vim /etc/init.d/nginx to ...
1
vote
1answer
41 views

NGINX: Route a call to localhost on a custom port to an external server

I have a problem with my rails app. An API of the app is looking for my forum (forum.example.com) on localhost on port 8082. I need to create a route that redirect every connection to 127.0.0.1:8082 ...
1
vote
0answers
36 views

Can't deploy Ruby 2, Rails 4 app to Linode

I have a Rails 4 app and I want to deploy it to my Linode and I'm struggling a lot to get this working. I followed all the basic instructions from the Linode guides, also, installed all the ...
0
votes
1answer
75 views

Rails 4 app + nginx1.4.4 + passenger4.0.37 on a headless Ubuntu12.x server running on a VM on my local machine

At the moment, it gives me a disapointing blank page. No 500, no 404, no errors on the nginx log file, just a snowstorm of interrogations. And its been hours of googling without success. So if anyone ...
-1
votes
2answers
25 views

Nginx: Changing user [closed]

I have root and deployer users in my ubuntu 13.10. I also have nginx, unicorn installed with Rails 4 application. I'm deploying my application using capistrano 3. Problem: When I prepare a env for ...
0
votes
1answer
187 views

Blocking/redirecting port 3000 with Nginx and Ruby On Rails (thin server)

I am setting up a server now that uses Ruby on Rails with the Thin server. I have set up Nginx to redirect all of my http://mysite.com to https://mysite.com(with ssl). I want all network traffic to ...
1
vote
0answers
98 views

Nginx Returning 504 Error

I'm getting a 504 error from Nginx on my Ubuntu server where I'm running Rails using Unicorn. When I look in the Nginx error.log.1, I see: 2014/01/21 18:06:02 [error] 698#0: *2 connect() failed ...
1
vote
2answers
59 views

Why server writes much more than reading the disk

I'm running one Ruby on Rails application, I use Passenger Nginx, Ruby on Rails 3.2, search gem Sunspot (which uses Solr as its search engine). My application works ok with around 6K active users but ...
1
vote
0answers
223 views

How to setup cross domain rules in discourse?

So i use the following page to gather information from the user and send it to forums.awake-gaming.com/posts for discourse to make a post for me . Url of page : awake-gaming.com/join-us.html Url, ...
0
votes
0answers
16 views

Configure nginx+passenger rails+phpmyadmin [duplicate]

I need to setup all routes to my rails server, except one: phpmyadmin path, i try so, my configuration file code: server { listen 80; server_name localhost; location / ...
1
vote
2answers
200 views

Explain load-balancing with Nginx like I'm five

I've found plenty of DIY posts and tutorials on how to configure Nginx as a load-balancer using upstream server: upstream backend { ip_hash; server 1.2.3.4; server 1.2.3.5; server 1.2.3.6; } ...
1
vote
0answers
141 views

nginx configuration for rails subdir deployment

I'm having quite a bit of trouble configuring nginx to serve my Rails app's static files; I mean all the files in the app's public/ folder, not just the files in Rails' asset pipeline. It seems I'm ...
0
votes
1answer
195 views

Nginx, Passenger, Rails serving static files but not running app

I've seen other similar questions but none with satisfactory answers, so here goes. I've installed Ruby, Rails, Nginx and Passenger and tried to configure it to all work together. Here is the ...
0
votes
1answer
213 views

Does Nginx require an index file for the root directory?

I'm developing a Rails application, and I'm now making the production environment default. I created the directive server { listen 127.0.0.1:80; server_name example.com; root ...
0
votes
0answers
8 views

File Checking Rewriting and Handing off to Rails

I have a requirement for Nginx to serve a file if it exists or hand off to a Rails controller. The URI is data?x=X&y=Y&z=Z which at the moment goes direct to a Rails controller, sends the file ...
1
vote
2answers
242 views

How to setup nginx server with wildcard DNS

This is about an sample Rails app that uses subdomains. You can access it here: http://rodrigora.com.br. In this app, you can create site and specify one subdomain for it. Example: site: ...
0
votes
0answers
33 views

How can I run a small app along side a Discourse install, using the same method Discourse uses to run?

I followed a slightly outdated version of the Discourse Install on Ubuntu Guide to get my forum up and running at something like forum.mysite.com. Now, I have a very small, related rails app that I'd ...
0
votes
0answers
758 views

nginx passenger_root not accepting valid passenger gem location

I am trying to add passenger_root and passenger_ruby to my nginx.conf file, but when i try and restart NGINX I get the message: Starting nginx: nginx: [alert] Unable to start the Phusion Passenger ...
1
vote
1answer
306 views

Nginx proxying websockets, connections not closed

I'm confused about where the problem is located, but basically I have nginx proxying websocket connections to a backend ruby thin server, which services the connections with the websocket-rails module ...
0
votes
1answer
107 views

nginx: simplify config for force ssl on specific path for rails app

im using the config below. it works, but the problem for me is the repeating of some lines. the proxy_* directives need to be in location /admin also, because only one location will be executed by ...
0
votes
0answers
76 views

Nginx Content-Type / Content-Disposition error when submitting POST form

I have a simple form with a button to delete a Rails model object. = form_for @object, html: { method: :delete } do |f| = f.submit It creates this HTML: <form accept-charset="UTF-8" ...
0
votes
1answer
131 views

How to configure rewrite rule for nginx over already binded port

My application is found here: http://my.app.com:3000/ My assets are found here: http://my.app.com:3000/dev-assets My application references assets here: http://my.app.com:3000/assets I'm using a ...
0
votes
1answer
53 views

How to do Caching only for specific IP's, in Nginx or Rails

We have a Rails 2.3.8 app running on a nginx/passenger server. Recently the crawlers generate a huge load on us. We'd like to turn on page caching ONLY for crawlers (specific IP addresses), i.e., ...
1
vote
0answers
70 views

Deploying sinatra app on rails app sub uri using( unicorn and nginx)

I have rails app running on unicorn+nginx. below is the nginx.conf and unicorn.rb configuration. nginx.conf upstream unicorn { server unix:/tmp/unicorn.todo.sock fail_timeout=0; } server{ ...
0
votes
1answer
65 views

phusion passenger processes dying and new ones starting up mysteriously

as you can see, passenger processes are dying and new ones booting up, even though we're not explicitly restarting passenger ourselves. we can't pinpoint what's causing this. what are some common ...
1
vote
2answers
280 views

Trying to install wordpress inside rails app with nginx and fastcgi

I have a rails app (let's call it myapp) running at www.myapp.com. I want to add a wordpress blog at www.myapp.com/blog. The webserver for the rails app is thin (see the upstream block). The wordpress ...
0
votes
1answer
358 views

Why does amazon ec2 have downtime after deploy when other identical servers do not?

This has puzzled me for the past few months...I'm admittedly new to server administration and I took a stab running a production rails app over at EC2. While I've learned a lot and feel pretty ...
0
votes
2answers
74 views

App got press, then servers got owned. I added 8 more servers, STILL too slow [duplicate]

Our new app has received a lot of press today, and is getting thousands of new users every hour... but it has become so slow that it's unusable. We're using Rails 3 patched to latest, ubuntu, ...
0
votes
0answers
174 views

Why do I need to precompile Rails assets on app servers?

I'm deploying a simple Rails app to this small ubuntu precise64 server setup : * 1 server running nginx * 2 servers running unicorn * 1 server running postgresql My servers are provisionned with ...
0
votes
2answers
268 views

Can we run Ruby on Rails app and a Wordpress blog in the same server? How?

Im running Nginx on my PS server. It have three Wordpress websites. Im trying to start converting one website into a Rails application. First I will convert only the front page. The other sections run ...
0
votes
1answer
177 views

Multiple Rails/Rack apps Nginx one for each subdomain

I just hired a VPS with Ubuntu 12.10 x64. I've managed to get one Rails app running with passenger-nginx. Now I want to run another app as a subdomain, say for example admin.mydomain.com. How can I do ...
1
vote
2answers
195 views

Nginx + Unicorn multiple apps with locations - routing

I would like to run multiple rails apps with just using different location blocks. Different unicorn workers are started and configured, they are working just fine. Every app is under the same ...
0
votes
1answer
125 views

Pass on passenger_base_uri to Rails app

We built a Rails app that consists of the following routes: namespace :api do namespace :v1 do resources ... end end That means, all controllers are reachable via ...
1
vote
1answer
244 views

setup Nginx, uwsgi for RAILS app on non-root location

I've set up and run a RAILS app (graylog2), and bellow config made it worked for root location: server { server_name www.mydomain.com; location / { gzip off; uwsgi_modifier1 ...
0
votes
0answers
211 views

How to set up SPDY Protocol over Nginx?

I am having problem setting up the SPDY protocol for my rails app over nginx. Here is the complete detail of the setup on stackoverflow. ...
0
votes
1answer
312 views

Nginx + Unicorn Rails Application gets 404 when requests number are high

I have a Rails application deployed using Nginx + Unicorn. Last night, when the traffic peaked, Nginx was getting lots of 404 errors. When I dig into logs, those 404 requests on the nginx side did not ...