-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcapistrano.rb
More file actions
32 lines (24 loc) · 786 Bytes
/
capistrano.rb
File metadata and controls
32 lines (24 loc) · 786 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
set :application, 'publishing-guide'
set :repository, '_site'
set :scm, :none
set :deploy_via, :copy
set :copy_compression, :gzip
set :use_sudo, false
set :host, 'lb1.stinkyink.com'
role :web, host
role :app, host
role :db, host, :primary => true
set :user, 'deploy'
set(:dest) { Capistrano::CLI.ui.ask("Destination: ") }
set :deploy_to, "/home/#{user}/apps/#{application}"
before 'deploy:update', 'deploy:update_jekyll'
namespace :deploy do
[:start, :stop, :restart, :finalize_update].each do |t|
desc "#{t} task is a no-op with jekyll"
task t, :roles => :app do ; end
end
desc 'Run jekyll to update site before uploading'
task :update_jekyll do
%x(rm -rf _site/* && jekyll build)
end
end