capistrano-nrsysmond 0.0.1 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,23 +1,36 @@
|
|
|
1
1
|
Capistrano::Configuration.instance(:must_exist).load do
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
namespace :newrelic do
|
|
6
|
-
desc 'Installs the newrelic sysmond'
|
|
7
|
-
namespace :sysmond do
|
|
8
|
-
task :default do
|
|
9
|
-
if newrelic_licencekey.nil?
|
|
10
|
-
abort <<-ERROR
|
|
3
|
+
_cset :newrelic_licencekey, {
|
|
4
|
+
abort <<-ERROR
|
|
11
5
|
define :newrelic_licencekey
|
|
12
6
|
|
|
13
7
|
This can be done via:
|
|
14
8
|
config/deploy.rb:
|
|
15
9
|
set :newrelic_licencekey, 'sakjfhsdjkgd'
|
|
16
10
|
$ cap deploy -s newrelic_licencekey=325398572395
|
|
17
|
-
|
|
18
|
-
|
|
11
|
+
ERROR
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
namespace :newrelic do
|
|
15
|
+
desc 'Installs the newrelic sysmond'
|
|
16
|
+
namespace :sysmond do
|
|
17
|
+
task :default do
|
|
19
18
|
install::default
|
|
20
19
|
end
|
|
20
|
+
namespace :uninstall do
|
|
21
|
+
task :default do
|
|
22
|
+
abort "nrsysmond not found?" unless remote_file_exists? '/etc/newrelic/nrsysmond.cfg'
|
|
23
|
+
debian if remote_file_exists? '/etc/debian_version'
|
|
24
|
+
redhat if remote_file_exists? '/etc/redhat-release'
|
|
25
|
+
end
|
|
26
|
+
task :debian do
|
|
27
|
+
sudo 'rm -f /etc/apt/sources.list.d/newrelic.list && apt-get remove newrelic-sysmond'
|
|
28
|
+
end
|
|
29
|
+
task :redhat do
|
|
30
|
+
sudo "yum uninstall -y newrelic-sysmond newrelic-repo-5-3.noarch.rpm"
|
|
31
|
+
end
|
|
32
|
+
before :default, '::newrelic::sysmond::stop'
|
|
33
|
+
end
|
|
21
34
|
namespace :install do
|
|
22
35
|
task :default do
|
|
23
36
|
unless remote_file_exists? '/etc/newrelic/nrsysmond.cfg'
|
metadata
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: capistrano-nrsysmond
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
hash:
|
|
4
|
+
hash: 27
|
|
5
5
|
prerelease:
|
|
6
6
|
segments:
|
|
7
7
|
- 0
|
|
8
|
-
- 0
|
|
9
8
|
- 1
|
|
10
|
-
|
|
9
|
+
- 0
|
|
10
|
+
version: 0.1.0
|
|
11
11
|
platform: ruby
|
|
12
12
|
authors:
|
|
13
13
|
- David Collom
|
|
@@ -15,7 +15,7 @@ autorequire:
|
|
|
15
15
|
bindir: bin
|
|
16
16
|
cert_chain: []
|
|
17
17
|
|
|
18
|
-
date: 2013-04-
|
|
18
|
+
date: 2013-04-28 00:00:00 Z
|
|
19
19
|
dependencies:
|
|
20
20
|
- !ruby/object:Gem::Dependency
|
|
21
21
|
name: capistrano
|
|
@@ -23,12 +23,13 @@ dependencies:
|
|
|
23
23
|
requirement: &id001 !ruby/object:Gem::Requirement
|
|
24
24
|
none: false
|
|
25
25
|
requirements:
|
|
26
|
-
- -
|
|
26
|
+
- - ~>
|
|
27
27
|
- !ruby/object:Gem::Version
|
|
28
28
|
hash: 3
|
|
29
29
|
segments:
|
|
30
|
+
- 2
|
|
30
31
|
- 0
|
|
31
|
-
version: "0"
|
|
32
|
+
version: "2.0"
|
|
32
33
|
type: :runtime
|
|
33
34
|
version_requirements: *id001
|
|
34
35
|
description: Capistrano recipe for installing the newrelic sysmond service on multiple operating systems
|