Sha256: f41ab0fbfcab5a9c61afb123f66a3d86b925acb32be45067565560bc522d7305
Contents?: true
Size: 1.24 KB
Versions: 2
Compression:
Stored size: 1.24 KB
Contents
# coding: utf-8 require 'capistrano_colors' require 'rvm/capistrano' set :rvm_type, :system require 'pit' config = Pit.get('tdiary', :require => { :username => 'your username', :server => 'your server address' }) set :application, 'tdiary' set :scm, :git set :repository, 'git://github.com/tdiary/tdiary-core.git' set :branch, 'master' set :deploy_via, :remote_cache server config[:server], :app set :user, config[:username] set :deploy_to, defer { "/home/#{user}/app/#{application}" } namespace :deploy do task :start do ; end task :stop do ; end task :restart, :roles => :app, :except => { :no_release => true } do run "touch #{File.join(current_path, 'tmp', 'restart.txt')}" end desc 'update shared library' task :update_library, :roles => :app do run "cp -r #{shared_path}/lib/* #{latest_release}/misc/lib" run "cp -r #{shared_path}/js/* #{latest_release}/js" end after 'deploy:finalize_update', 'deploy:update_library' after 'deploy:update', 'deploy:cleanup' end namespace :httpd do [:stop, :start, :restart, :reload].each do |action| desc "#{action.to_s.capitalize} Apache" task action, :roles => :app do invoke_command "/etc/init.d/apache2 #{action.to_s}", :via => run_method end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
tdiary-3.2.2.20130508 | tdiary/deploy.rb |
tdiary-3.2.2.20130507 | tdiary/deploy.rb |