Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>In order to deploy to a production server with Phusion Passenger you need to use the <code>RailsEnv production</code> directive as you have.</p> <p>But you also need to ensure that the associated Rails environment is configured correctly. These files are stored in <code>apps/config/environments/</code> and a new Rails project comes with 3: <code>development</code> (the default), <code>test</code>, and <code>production</code>. You can add others, for example <code>staging</code> by adding files to this directory.</p> <p>Each file has a number of settings that make sense for the environment. In development, you want nice verbose logging, plain-text CSS and JS files, and errors to show up in the browser. In production, you want everything to be as fast as possible: terse logging, compiled assets, user-friendly error pages.</p> <p>In your case, the assets used by Rails (notably all of the CSS and JS files) have not yet been processed by the Rails "asset pipeline". There's a rake task for precompiling assets (<code>rake assets:precompile</code>) which is what the default <code>production</code> environment expects. The default development environment compiles CoffeeScript and SASS files to JS and CSS respectively on the fly, and does minimal processing otherwise.</p> <p>So as part of deploying to production, you'll need to run this rake task any time you add or make a change to any assets. Because this and numerous other similar details are required every time you deploy, there's a great gem called Capistrano, which most Rails apps use for deployment. It's a whole other beast, to be sure, but as you get further along the process, you'll definitely want to consider it. Even a minimally configured capistrano script would know to precompile assets and restart the server when it's done, etc.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload