diff options
| author | mo khan <mo@mokhan.ca> | 2013-08-09 11:41:57 -0600 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2013-08-09 11:41:57 -0600 |
| commit | 530439b374e18fda6c6d6b81e07d2e6f304785ba (patch) | |
| tree | 5c1e1ca22ca670963e5b03a99f94121debd071f5 | |
| parent | 9c889028be05270f3cfef1e926c75da2882bafe4 (diff) | |
create cap task to tail the server logs
| -rw-r--r-- | config/deploy.rb | 3 | ||||
| -rw-r--r-- | config/recipes/server.rb | 4 |
2 files changed, 7 insertions, 0 deletions
diff --git a/config/deploy.rb b/config/deploy.rb index 0ac0220..81b74a3 100644 --- a/config/deploy.rb +++ b/config/deploy.rb @@ -9,6 +9,8 @@ load "config/recipes/nodejs" load "config/recipes/rbenv" load "config/recipes/newrelic" load "config/recipes/monit" +# general tasks +load "config/recipes/server" set :application, "parley" set :user, "deployer" @@ -29,3 +31,4 @@ after "deploy", "deploy:cleanup" # keep only the last 5 releases # cap deploy:setup # cap deploy:cold # cap nginx:start # this may be necessary if it didn't start up properly before + diff --git a/config/recipes/server.rb b/config/recipes/server.rb new file mode 100644 index 0000000..6d71371 --- /dev/null +++ b/config/recipes/server.rb @@ -0,0 +1,4 @@ +desc "tail the logs on an app server (cap qa logs)" +task :logs, roles: :app do + stream "tail -f #{shared_path}/log/#{rails_env}.log" +end |
