【发布时间】:2011-03-24 09:12:52
【问题描述】:
我有一个整合 Rails 项目多个阶段的部署的 capistrano 任务。
例如:
task :consolidated_task do
build #creates a new release branch from master,
#sets a variable with the relese branch name
staging
deploy.migrations
production
deploy.migrations
end
这是从另一个上限任务调用多阶段任务的正确方法吗?
构建任务创建一个新的 git 分支并发布它。新分支的名称被保存为 capistrano 变量。登台和生产阶段任务然后使用这个变量来指定从哪个分支部署。
当这个任务运行时,它失败了:
fatal: working tree '/Users/<my working directory>' already exists.
/usr/local/lib/ruby/gems/1.8/gems/capistrano-2.5.19/lib/capistrano/recipes/deploy/strategy/copy.rb:99:in `initialize': No such file or directory - /var/folders/3d/3dKYNUwQGOSLZFXsMF-uv++++TM/-Tmp-/20100802182750/REVISION (Errno::ENOENT)
我正在从本地机器推送源,因为 git 存储库和部署机器无法相互通信。
【问题讨论】:
-
现在是 100%。我一定是超级用户!
标签: ruby-on-rails deployment capistrano