1
0
Fork 0
mirror of https://github.com/capistrano/capistrano synced 2023-03-27 23:21:18 -04:00
capistrano/Rakefile

19 lines
452 B
Ruby

require 'time'
require 'sshkit'
deploy_to = '/opt/sites/capistranorb_com'
release_timestamp = Time.now.utc.strftime("%Y%m%d%H%m%S")
desc "Build Jekyll Site And Sync With S3"
task :deploy do
sh "jekyll build"
on 'harrow.io' do
upload! '_site/', deploy_to, recursive: true
within(deploy_to) do
execute :mv, '_site/', release_timestamp
execute :ln, '-snf', release_timestamp, 'public'
end
end
end
task :default => :deploy