Related Setup: https://gist.github.com/hofmannsven/6814278
Related Pro Tips: https://ochronus.com/git-tips-from-the-trenches/
Related Setup: https://gist.github.com/hofmannsven/6814278
Related Pro Tips: https://ochronus.com/git-tips-from-the-trenches/
| require 'mina/git' | |
| require 'mina/nginx' | |
| set :application, 'your_app_name' | |
| set :domain, 'your_server' | |
| set :user, 'ubuntu' | |
| set :deploy_to, '/location/to/deploy' | |
| set :app_path, "#{deploy_to}/#{current_path}" | |
| set :repository, 'your_repo' | |
| set :branch, 'master' |
| require 'sinatra' | |
| get '/long_process' do | |
| child_pid = Process.fork do | |
| # hard work is done here... | |
| sleep 10 | |
| Process.exit | |
| end | |
| Here's an example of a few different ways to call a method on a Ruby object. | |
| If you're a beginner, try running the code above to watch it in action. | |
| If you're not a beginner, go ahead and tear me a new one for whichever techniques I forgot ;) | |
| - Pat |