我使用capistrano 3.0.1和capistrano-rails 1.1.0進行部署。部署工作到目前爲止,只有assets:precompile
沒有得到執行。這階段是每次跳過此消息:沒有匹配主機的捆綁執行耙子資產:預編譯
WARN [SKIPPING] No Matching Host for /usr/bin/env if test ! -d /var/www/versioneye/releases/20140111161403; then echo "Directory does not exist '/var/www/versioneye/releases/20140111161403'" 1>&2; false; fi
WARN [SKIPPING] No Matching Host for bundle exec rake assets:precompile
WARN [SKIPPING] No Matching Host for /usr/bin/env if test ! -d /var/www/versioneye/releases/20140111161403; then echo "Directory does not exist '/var/www/versioneye/releases/20140111161403'" 1>&2; false; fi
WARN [SKIPPING] No Matching Host for /usr/bin/env cp /var/www/versioneye/releases/20140111161403/public/assets/manifest* /var/www/versioneye/releases/20140111161403/assets_manifest_backup
WARN [SKIPPING] No Matching Host for /usr/bin/env if test ! -d /var/www/versioneye/releases/20140111161403; then echo "Directory does not exist '/var/www/versioneye/releases/20140111161403'" 1>&2; false; fi
WARN [SKIPPING] No Matching Host for /usr/bin/env find public/images public/javascripts public/stylesheets -exec touch -t 201401111614.03 {} ';'; true
我config/deploy/stagging
只定義1的作用。
role :app, %w{[email protected]}
而在config/deploy.rb
我這樣設置asset_roles:
set :assets_roles, [:app] # Defaults to [:web]
任何想法,爲什麼assets:precompile
不到風度得到執行?