zabbix-monitor 0.0.3 → 0.0.5

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: 12d1f8315102ff4b17ac77c9353c7f36118fa66c
4
- data.tar.gz: fb155b2c351ef2637a8acc6e8bb2434c1cf0819a
3
+ metadata.gz: 83ad503b156902573a4ce874638a81cce5f94fb3
4
+ data.tar.gz: 5ca3a84bbb31d20fbda66e212344273db4126d86
5
5
  SHA512:
6
- metadata.gz: 5b113b81926b4c51174a10223b849a5b823636c7ccfadb8a5b33bb97d7569a590eccc67c44fa3bf4f617a0465beab5447f6bab1ab0617e409b4a0a7ae506ab24
7
- data.tar.gz: 766a16529f22c2d8097bd44cc82da091f8f45bb47889fea4974d24b49d995f296db54f1f19f74f1112929b8c71d765e855ce3e82ff12b7e8a7ce46b54c465e62
6
+ metadata.gz: 5547d7fa0e288525c5e36b31906243b2f7679bba4b7c20f948849bf7d5a1eaf6f21c11a53d5c8743d5636dabf96d87b9488dad7645e8dca44922e5e77d8965e7
7
+ data.tar.gz: ea691f026f9f89c2c2ed1388b69afbc7c489594a5c9bdf5606cee11afeabbd718f9cf5db959c5bd43ae2cbe108a61195f57db51499c790068f13221164da1e8a
data/lib/tasks/zabbix.rb CHANGED
@@ -21,4 +21,12 @@ namespace :zabbix do
21
21
  Zabbix.logger.info "[Rake] executing #stop, stopping daemon"
22
22
  Dante::Runner.new('zabbix-monitor').execute(:kill => true, :pid_path => 'tmp/zabbix-monitor.pid')
23
23
  end
24
- end
24
+
25
+ desc 'Restart collecting data for Zabbix'
26
+ task :restart => :environment do
27
+ Zabbix.logger.info "[Rake] executing #stop, stopping daemon"
28
+ Dante::Runner.new('zabbix-monitor').execute(:daemonize => true, :restart => true, :pid_path => 'tmp/zabbix-monitor.pid', :log_path => 'log/zabbix-monitor.log') do
29
+ Zabbix::Monitor.new.schedule
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,13 @@
1
+ require 'capistrano'
2
+
3
+ Capistrano::Configuration.instance.load do
4
+
5
+ after 'deploy:update_code', 'zabbix:restart'
6
+
7
+ namespace :zabbix do
8
+ desc 'Restarting Zabbix monitoring'
9
+ task :restart, :roles => :web do
10
+ run "cd #{release_path}; RAILS_ENV=#{rails_env} bundle exec rake zabbix:restart"
11
+ end
12
+ end
13
+ end
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = 'zabbix-monitor'
7
- spec.version = '0.0.3'
7
+ spec.version = '0.0.5'
8
8
  spec.authors = ['Robert Jan de Gelder', 'Manuel van Rijn']
9
9
  spec.email = ['r.degelder@sping.nl', 'm.vanrijn@sping.nl']
10
10
  spec.description = 'Zabbix application monitoring'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zabbix-monitor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Jan de Gelder
@@ -186,6 +186,7 @@ files:
186
186
  - bin/zabbix_reader
187
187
  - lib/tasks/zabbix.rb
188
188
  - lib/zabbix.rb
189
+ - lib/zabbix/capistrano.rb
189
190
  - lib/zabbix/config.rb
190
191
  - lib/zabbix/monitor.rb
191
192
  - lib/zabbix/reader.rb