gpt4 book ai didi

capistrano3 - 如何在 Capistrano 3 中设置 current_path

转载 作者:行者123 更新时间:2023-12-01 06:24:35 35 4
gpt4 key购买 nike

有没有办法在 Capistrano3 中设置当前路径文件夹。

我可以看到它现在是 Capistrano::DSL::Paths 的一部分模块,但我不确定如何更改它。

最佳答案

我用这样的东西解决了这个问题

set :current_path, "/somecurrentpathyouwant"

namespace :deploy do

desc "Create symlink to configured current path"
task :create_symlink do
on roles(:all) do
execute "rm -f #{fetch(:current_path)} && ln -s #{release_path} #{fetch(:current_path)}"
end
end

end

after :deploy, "deploy:create_symlink"

关于capistrano3 - 如何在 Capistrano 3 中设置 current_path,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30159459/

35 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com