Skip to content
Snippets Groups Projects
Commit 06ceabbb authored by elijah's avatar elijah
Browse files

added capistrano configs.

parent 783be829
Branches
No related tags found
No related merge requests found
require 'capistrano/setup'
require 'capistrano/deploy'
#
# this will allow you to run `cap deploy`
# instead of `cap production deploy`.
#
invoke :production
......@@ -9,5 +9,16 @@ render the source files into html files.
To submit changes, please fork this repo and issue pull requests on github.
For more information how to use `amber`, see: https://github.com/leapcode/amber.
For more information how to use `amber`, see:
https://github.com/leapcode/amber.
For now, there is no post-commit hook on this repo that automatically triggers
an update to the website. To deploy the current version:
sudo gem install capistrano
git clone https://leap.se/git/leap_se
cd leap_se
cap deploy
This will deploy directly from master branch of https://leap.se/git/leap_se
(in other words, local changes are not deployed).
\ No newline at end of file
set :application, "leap_se"
set :deploy_to, "/home/website/leap-website"
set :scm, :git
set :repo_url, "https://leap.se/git/leap_se"
set :branch, "master"
set :deploy_via, :remote_cache
set :use_sudo, false
set :keep_releases, 2
# use system gems:
set :default_environment, {
'GEM_PATH' => '',
'GEM_HOME' => ''
}
namespace :leap do
task :link_to_chiliproject do
on roles(:all) do |host|
execute "rm -f #{current_path}/public/code"
execute "ln -s /var/www/redmine/public #{current_path}/public/code"
end
end
end
namespace :amber do
task :rebuild do
on roles(:all) do |host|
within release_path do
execute :amber, 'rebuild'
end
end
end
end
after "deploy:updated", "amber:rebuild"
before "deploy:published", "leap:link_to_chiliproject"
server 'hare.leap.se',
roles:['app'],
user:'website',
port: 22,
ssh_options: {
auth_methods: ['publickey'],
forward_agent: false
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment