Configuring asset pipeline compilation
Cloud 66 gives you complete control over your asset pipeline:
- We will automatically run APC on each of your deploys. You can choose to disable this.
- You can nominate one of your servers to handle the APC workload, leaving your other servers free to run your application as usual.
Enable or disable APC
You can manually enable/disable APC either:
- When you first deploy your app (after the analysis step)
- In your manifest file (for apps that are already deployed)
You can use a manifest file to enable/disable the APC using the following parameters with a true or false:
Note that we must enable the pipeline and also set precompile to true (this is the default).
Any conflicts or gaps in APC settings will be resolved in the following order of priority:
- Cloud 66 manifest file
- The Cloud 66 dashboard
(i.e. the settings in your
application.rb will overrule anything in your manifest)
Nominating a dedicated compilation server
Compilation is a resource intensive process that can congest your servers. To mitigate this issue, you can nominate one of your application servers to act as a dedicated compiler. When you enable this feature, the compilation process changes as follows:
- Code is deployed to the dedicated server
- Assets are compiled on that server (using your settings)
- Code is deployed to the rest of your servers
- Assets are synched to the rest of your servers
We strongly recommend choosing your most powerful and/or least busy server to handle this load.
Enabling dedicated compilation
In order to designate a application server as your dedicated compiler, you need to:
- Log into your Cloud 66 Dashboard and click through to your Rails app
- Click through to the overview page for the server you plan to use as a compiler
- Click on the Tags icon and then Add Tags
- Add a tag named
The next time you redeploy your application assets will be compiled on the nominated server.