Closed timurvafin closed 10 years ago
@timurvafin why you removed middleman-deploy gem solution from https://github.com/fs/v2.flatstack.com/pull/100/files?
# config.rb
case ENV['TARGET'].to_s.downcase
when 'production'
activate :deploy do |deploy|
deploy.method = :rsync
deploy.host = 'www.example.com'
deploy.path = '/srv/www/production-site'
end
else
activate :deploy do |deploy|
deploy.method = :rsync
deploy.host = 'staging.example.com'
deploy.path = '/srv/www/staging-site'
end
end
# Rakefile
namespace :deploy do
def deploy(env)
puts "Deploying to #{env}"
system "TARGET=#{env} bundle exec middleman deploy"
end
task :staging do
deploy :staging
end
task :production do
deploy :production
end
end
$ rake deploy:staging
$ rake deploy:production
We need to have ability to deploy generated code to different Github pages. Take a look how it was done here https://github.com/fs/v2.flatstack.com/pull/100/files