0N/A desc 'Restart application'
0N/A task :set_revision do
0N/A # dump current git revision
0N/A rev = capture "cd #{repo_path} && git rev-parse --short #{fetch :branch}"
0N/A execute :echo, "#{rev} > #{release_path}/REVISION"
1186N/A desc "Moves and replaces the secret-token if missing in shared directory"
0N/A task :symlink_secret do
1186N/A unless test "[ -f #{shared_secret} ]"
1186N/A execute :rake, "secret:replace"
1281N/A execute :mv, "#{release_secret} #{shared_secret}"
1281N/A execute :ln, "-nfs #{shared_secret} #{release_secret}"
1281N/A after :updated, :symlink_secret
1281N/A after :updated, :set_revision
1281N/A after :publishing, :restart