1
我使用RVM轨,Capistrano的轨道跳过任务`部署:更新”,因为它以前被调用
使用Capistrano的deplying当我得到以下错误:
Skipping task `deploy:updating'.
Capistrano tasks may only be invoked once. Since task `deploy:updating' was previously invoked, invoke("deploy:updating") at /home/ziaulrehman/.rvm/gems/ruby-2.3.4/gems/capistrano-3.8.2/lib/capistrano/tasks/framework.rake:64 will be skipped.
If you really meant to run this task again, first call Rake::Task["deploy:updating"].reenable
THIS BEHAVIOR MAY CHANGE IN A FUTURE VERSION OF CAPISTRANO. Please join the conversation here if this affects you.
https://github.com/capistrano/capistrano/issues/1686
我capfile有:
require 'capistrano/setup'
require 'capistrano/deploy'
require 'capistrano/bundler'
require 'capistrano/rails'
require 'rvm1/capistrano3'
require 'capistrano/puma'
require 'capistrano/sidekiq'
install_plugin Capistrano::Puma
install_plugin Capistrano::Puma::Nginx
require "capistrano/scm/git"
install_plugin Capistrano::SCM::Git
require "capistrano/rails/assets"
# there are no customm tasks
Dir.glob("lib/capistrano/tasks/*.rake").each { |r| import r }
而且我deploy.rb看起来像:
# config valid only for current version of Capistrano
lock "3.8.2"
set :application, "webapp"
set :deploy_via, :remote_cache
set :keep_releases, 5
set :repo_url, "[email protected]:org/webapp.git"
append :linked_files, 'config/database.yml', 'config/secrets.yml', '.env.generic'
append :linked_dirs, 'vendor/bundle', 'public/uploads'
# Default deploy_to directory is /var/www/my_app_name
set :deploy_to, "/home/deployer/www/webapp"
set :rvm1_ruby_version, 'ruby-2.3.4'
# set :rvm_type, :user
# set :default_env, { rvm_bin_path: '~/.rvm/bin' }
# fetch(:default_env).merge!(rvm_path: '~/.rvm/bin')
set :rvm1_map_bins, -> { fetch(:rvm_map_bins).to_a.concat(%w{rake gem bundle ruby foreman}).uniq }
before 'deploy', 'rvm1:install:ruby'
set :sidekiq_processes => 2
set :keep_assets, 2
set :sidekiq_config => '#{release_path}/config/sidekiq.yml'
set :pty, true
我绝对没有自定义任务什么的,这些都是我使用所有的宝石,我怀疑某种宝石中的冲突。
如果有人能指出确切位置正在创建这个问题,我怎么能解决这个问题,将是巨大的。另外,我想知道这个问题的含义。一切似乎现在正常工作。
三江源很为你分析,这种宝石是一个非常标准之一。我会在gem repo上为这个问题打开一个问题,并将这个答案链接到那里。这是积极的开发和使用,所以它会很奇怪,如果它可以为所有其他用户的宝石,只有我有问题。但是,就你的分析而言,它仍然是一个问题。谢谢 –