capistrano-devops 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bb762a5df31afd7dbbb7dfd068b99a22df9bc89e
4
- data.tar.gz: 73aa1d0a9f46a26d81912acd1a5977a33b6ceee6
3
+ metadata.gz: eba69848b365f41bf57691041ed336f90c4a7913
4
+ data.tar.gz: 23170fe2ba77ccef73946233c63b0b8cb9fe6274
5
5
  SHA512:
6
- metadata.gz: d0a0f0bd27a41e04c080ee3ef0425127c5f366870d7ce9568742beacf34d754dd98269b88af24056afdff3aa4db4bffce6747102ded316f6e084e659f554742f
7
- data.tar.gz: 75bcd6ef3704415f47ddbce0f9644fa0b48d1dcfac2274ac794dbf21f12c4f14f46483fa9ab30369894d422f7ac11f55c7bb9c3115e41787b5f391b8bbd94cf2
6
+ metadata.gz: d7b9f9de45a9f713c6072ff5dfe1b81a67cda1d91b50da0a711a647f1907df3facb782023955bebebe78c9bfe245ebf0a217953eac2060c8cb8443540121b41e
7
+ data.tar.gz: 9ddfb7affac8e3bc2e112e1ac34e8d059d17620d4d704280fcf8f4b1e21249a8cea147ee6182152fce735c7e5b85884769d72918dffef38c8f3c78d8054c1c7c
@@ -1,5 +1,5 @@
1
1
  module Capistrano
2
2
  module Devops
3
- VERSION = "0.0.2"
3
+ VERSION = "0.0.3"
4
4
  end
5
5
  end
@@ -21,18 +21,21 @@ namespace :papertrail do
21
21
 
22
22
  # desc 'Install remote_syslog on all app servers'
23
23
  task :remote_syslog do
24
- on roles(:app) do
24
+ on roles(:app) do |host|
25
25
  as :root do
26
+ # TODO: only install the gem if the command doesn't exist
27
+ # maybe which remote_syslog ?
26
28
  execute :gem, 'install remote_syslog'
27
29
 
28
30
  LOG_FILES_YML = <<-EOF
29
31
  files:
30
- - #{shared_path.join('log').to_s}/*
32
+ - #{shared_path.join('log').to_s}/*.log
31
33
  destination:
32
34
  host: #{fetch(:papertrail_host, 'logs.papertrailapp.com')}
33
35
  port: #{fetch(:papertrail_port, 1234)}
34
- prepend: #{fetch(:application)}
35
- EOF
36
+ prepend: #{capture('hostname')} ->
37
+ hostname: #{fetch(:application)}-#{host}
38
+ EOF
36
39
 
37
40
  within '/etc' do
38
41
  # again, DRY this up (because as() doesn't work with upload! or within yet)
@@ -51,8 +54,8 @@ respawn
51
54
 
52
55
  pre-start exec /usr/bin/test -e /etc/log_files.yml
53
56
 
54
- exec /usr/local/bin/remote_syslog -D --tls
55
- EOF
57
+ exec /usr/local/bin/remote_syslog -D
58
+ EOF
56
59
 
57
60
  # TODO: find out where the remote_syslog is (or if it even got installed)
58
61
  # find / -name remote_syslog
@@ -63,7 +66,7 @@ exec /usr/local/bin/remote_syslog -D --tls
63
66
 
64
67
  end
65
68
 
66
- execute :service, 'remote_syslog start'
69
+ execute :service, 'remote_syslog restart'
67
70
 
68
71
  end
69
72
  end
@@ -22,9 +22,9 @@ GIT
22
22
 
23
23
  GIT
24
24
  remote: git://github.com/parasquid/capistrano-devops.git
25
- revision: cef01cf1a586a3584454ecdea62d4d45d4cf117e
25
+ revision: bebdfb4ac33f80fba5cc06e93af96ced0f741f9a
26
26
  specs:
27
- capistrano-devops (0.0.1)
27
+ capistrano-devops (0.0.2)
28
28
  capistrano (~> 3)
29
29
  capistrano-bundler
30
30
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capistrano-devops
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - tristan