engineyard-serverside 2.5.0.cs → 2.5.0.cs2
Sign up to get free protection for your applications and to get access to all the features.
@@ -77,6 +77,7 @@ module EY
|
|
77
77
|
|
78
78
|
def_option :precompile_assets, 'detect'
|
79
79
|
def_option :precompile_assets_task, 'assets:precompile'
|
80
|
+
def_option(:precompile_assets_command) { "rake #{precompile_assets_task} RAILS_GROUPS=assets" }
|
80
81
|
def_option :asset_strategy, 'shifting'
|
81
82
|
def_option :asset_dependencies, %w[app/assets lib/assets vendor/assets Gemfile.lock config/routes.rb config/application.rb]
|
82
83
|
def_option :asset_roles, [:app_master, :app, :solo]
|
@@ -52,10 +52,10 @@ module EY
|
|
52
52
|
def run_precompile_assets_task
|
53
53
|
asset_strategy.prepare do
|
54
54
|
cd = "cd #{paths.active_release}"
|
55
|
-
task = "PATH=#{paths.binstubs}:$PATH #{framework_envs}
|
55
|
+
task = "PATH=#{paths.binstubs}:$PATH #{framework_envs} #{precompile_assets_command}"
|
56
56
|
|
57
57
|
shell.status "Compiling assets once"
|
58
|
-
|
58
|
+
system("sh -l -c '#{cd} && #{task}'")
|
59
59
|
|
60
60
|
shell.status "Syncing assets to remote servers"
|
61
61
|
runner.servers.remote.run_for_each do |server|
|