passenger

403 Forbidden when using nginx + rails + passenger

杀马特。学长 韩版系。学妹 提交于 2019-12-11 06:44:05
问题 I am getting a 403 when I try to access my rails app running on top of nginx and passenger. Here is the error from the log file: 2013/05/09 13:52:34 [error] 27787#0: *1 directory index of "/var/www/Tread-Forth/current/public/" is forbidden, client: 192.249.16.60, server: treadforth.com, request: "GET / \ HTTP/1.1", host: "www.treadforth.com" This problem occurs even when I run nginx as root, so I don't think it is a permissions problem. I think the problem is that I do not have passenger_ruby

Multiple database.yml but one application

对着背影说爱祢 提交于 2019-12-11 05:20:08
问题 The Setup I have a Ruby on Rails application that I manage from a sysadmin perspective. This application in installed on a pool of load balanced application servers. These application servers a running Apache 2 and Passenger 3.0. The application files are stored in a ramdisk because IO on the application servers are ridiculously slow. Database configuration The backend database is stored on a pair of MySQL clusters (active/passive). Several clients use our application and each have a separate

Django url template tags adding absolute filepath

邮差的信 提交于 2019-12-11 04:54:01
问题 I am having a problem where my {% url %} django template tag is adding the filepath to the web address in production. This is not replicated on my local development machine. With urls.py setup such that: url("^about_us/$", views.about_us, name="about_us"), In production, I am getting the link www.mysite.com/home/username/myapp/about_us instead of www.mysite.com/about_us I have looked at this similar issue and it does not help with my specific application: Django url tag adds filepath My

Centos+Apache+passenger+rails: running rails apps from your www folder

不羁岁月 提交于 2019-12-11 03:58:23
问题 I'm trying to learn Rails, so I'm new, and would like a little help. I'm trying to run multiple apps at once, and I'm having an odd problem. When I try to generate things with rails, it gives me a permissions error. I've looked around stackoverflow and several other sites and haven't found any good solutions. Details: This setup successfully runs two rails apps in these locations: http://rails.mechapps.co/ http://slide.mechapps.co/ 2 currently shows an error because of a missing controller (4

Keep getting 504 Gateway Time-out after deploying on ec2 using rubber

南笙酒味 提交于 2019-12-11 03:24:10
问题 I used the rubber gem to deploy my application on ec2. I followed the instructions here: http://ramenlab.wordpress.com/2011/06/24/deploying-your-rails-app-to-aws-ec2-using-rubber/. The process seems to finish successfully but when I try to use the app I keep getting 504 gateway time-out. Why is this happening and how do I fix it? 回答1: Answer from Matthew Conway (reposted below): https://groups.google.com/forum/?fromgroups#!searchin/rubber-ec2/504/rubber-ec2/AtEoOf-T9M0/zgda0Fo1qeIJ Note: Even

RVM, Ruby 1.9.2, Rails 3, Passenger 3.0.2 (Bundler::GemNotFound)

ぃ、小莉子 提交于 2019-12-11 03:05:49
问题 I'm using RVM, Ruby 1.9.2, Rails 3, Passenger 3.0.2 configured for Nginx, I setup server configuration correctly. Another app working so far. But for the new app, when booting server http://myapp.local (its configured with hosts to point server bind on Nginx conf) It returns (Bundler::GemNotFound) error. How to get around this? Thanks. 回答1: Believe it or not this is a very common problem most Rails Developers will come across. Have a look at this post which details the fix I think you are

How to get ruby on rails production mount-point included in url_helpers for email?

允我心安 提交于 2019-12-11 02:54:46
问题 tl;dnr : My page links are fine, but links erb-olated into non-page text (email) lack the production app mount-point. detail : My RoR app uses slightly different URLs in dev and production: in dev, the top-level entity is the resource model: http://localhost:3000/ENTITY/1/edit But in production, the app is mounted one level down, so URLS have an extra term: https://server.example.com/APP/ENTITY/1/edit This works fine for most cases: url_helpers like edit_entity_url return the URLs as I've

Getting “development” errors in production mode

一个人想着一个人 提交于 2019-12-11 02:23:02
问题 I'm having a strange problem: I'm running my server in production mode, everything is fine, but I keep getting error messages like they appear in development mode. So for example instead of a 404 page, I'm getting "No route matches "/foo" with {:method=>:get}". Also "exception notifier" stopped sending exceptions. I put <%= "Environment: #{RAILS_ENV}" %> into a view, to double-check I am definitly in production mode, which is true. Never had this before. I'm on rails 2.3.8 on a shared server,

Nginx Upload Progress Module with Rails and Passenger

故事扮演 提交于 2019-12-11 01:09:40
问题 I’ve been trying to get the Nginx upload progress module running on WebFaction with Rails and Passenger (using Paperclip to upload to S3). The best result I have come up with so far are that it reports on start and on finish, but nothing in between. The Ajax request to the /progress path is working fine. This is the nginx.conf file I have setup: http://pastie.org/835075 Any ideas? 回答1: What does the XHR request say midstream? If it says "starting" I solved it by changing the order of

I can't run rails console with Docker and Passenger/nginx image

人走茶凉 提交于 2019-12-11 00:37:59
问题 I've the next docker-compose container: # docker-compose.yml version: '2' services: web: build: . ports: - "80:80" volumes: - .:/home/app/NAME_OF_MY_APP db: image: postgres:9.4 ports: - "5432" environment: POSTGRES_USER: 'postgres' I cannot figure out how can I run the rails console. I'm using the passenger/nginx image and everything is working. However, my DB is on another container and I'd like to entry at rails console to create manually a couple of users. I tried with: sudo docker-compose