我已經安裝了RVM和Capistrano,但似乎遇到了錯誤。Capistrano 3.1.0部署問題與Rake> = 10.2.0
我的Gemfile:
source 'https://rubygems.org'
gem 'sass'
gem 'compass'
gem 'capistrano-rvm'
gem 'capistrano', '~> 3.1.0'
我的紅寶石版本:
$ ruby -v
ruby 2.1.1p76 (2014-02-24 revision 45161) [x86_64-darwin12.0]
然後我運行:
$ cap install
mkdir -p config/deploy
create config/deploy.rb
create config/deploy/staging.rb
create config/deploy/production.rb
mkdir -p lib/capistrano/tasks
Capified
然後:
$ cap deploy:check
cap aborted!
TypeError: no implicit conversion of Rake::Task into String
/Users/ianjamieson/.rvm/gems/ruby-2.1.1/gems/capistrano-3.1.0/lib/capistrano/application.rb:15:in `run'
/Users/ianjamieson/.rvm/gems/ruby-2.1.1/gems/capistrano-3.1.0/bin/cap:3:in `<top (required)>'
/Users/ianjamieson/.rvm/gems/ruby-2.1.1/bin/cap:23:in `load'
/Users/ianjamieson/.rvm/gems/ruby-2.1.1/bin/cap:23:in `<main>'
/Users/ianjamieson/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `eval'
/Users/ianjamieson/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `<main>'
(See full trace by running task with --trace)
返回任何東西的唯一帽的命令是:
$ cap -V
Capistrano Version: 3.1.0 (Rake Version: 10.2.1)
$ cap -vT
cap deploy # Deploy a new release
cap deploy:check # Check required files and directories exist
cap deploy:check:directories # Check shared and release directories exist
cap deploy:check:linked_dirs # Check directories to be linked exist in shared
cap deploy:check:linked_files # Check files to be linked exist in shared
cap deploy:check:make_linked_dirs # Check directories of files to be linked exist in shared
cap deploy:cleanup # Clean up old releases
cap deploy:cleanup_rollback # Remove and archive rolled-back release
cap deploy:finished # Finished
cap deploy:finishing # Finish the deployment, clean up server(s)
cap deploy:finishing_rollback # Finish the rollback, clean up server(s)
cap deploy:log_revision # Log details of the deploy
cap deploy:published # Published
cap deploy:publishing # Publish the release
cap deploy:revert_release # Revert to previous release timestamp
cap deploy:reverted # Reverted
cap deploy:reverting # Revert server(s) to previous release
cap deploy:rollback # Rollback to previous release
cap deploy:started # Started
cap deploy:starting # Start a deployment, make sure server(s) ready
cap deploy:symlink:linked_dirs # Symlink linked directories
cap deploy:symlink:linked_files # Symlink linked files
cap deploy:symlink:release # Symlink release to current
cap deploy:symlink:shared # Symlink files and directories from shared to release
cap deploy:updated # Updated
cap deploy:updating # Update server(s) by setting up a new release
cap install # Install Capistrano, cap install STAGES=staging,production
任何想法?
不錯!不能相信這是問題! '$ cap'現在返回'Stage沒有設置,請打電話給'cap production deploy',其中生產是你定義的一個階段。 –