Sha256: 800a96b7bac6f730b9d2dd28470399896dc044284411c87e3881f8bd5a9130c5
Contents?: true
Size: 759 Bytes
Versions: 39
Compression:
Stored size: 759 Bytes
Contents
namespace :git do desc 'Git pull for common code project' task :pull_common do on roles(:app) do within "/var/www/common" do execute :git, :pull, :origin, :master end if test("[ -d /var/www/common ]") end end after "deploy:updating", "git:pull_common" desc 'Deploy from local git repository' task :deploy_from_local_repo do set :repo_url, "file:///tmp/.git" run_locally do execute "tar -zcvf /tmp/repo.tgz .git" end on roles(:all) do upload! '/tmp/repo.tgz', '/tmp/repo.tgz' execute 'tar -zxvf /tmp/repo.tgz -C /tmp' end end desc 'Removes repo (useful when repo_url changes)' task :remove_repo do on roles(:all) do execute "rm -r #{repo_path}" end end end
Version data entries
39 entries across 39 versions & 1 rubygems