capistrano-spy 0.1.4

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.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 2f9f5dd6ce13b2bf6211dd7c0de344d2cb7dfceb
4
+ data.tar.gz: 83a7aae6fc7e8168295e217e9b03b5dd36cb0d9e
5
+ SHA512:
6
+ metadata.gz: 0e7c9eafc5101c2148e507b1ecd691ed64b620302acb6a17c145bebcd59b95eaaabe7f4d4b50017e0c7851e162c6d01903bfb22d9f04f7de393bd1f2393f4d1a
7
+ data.tar.gz: e25b97c8b62589a66dcbcb819be90fda668aec5bbe09b89b948377c3427d2ede8b8f8014ec65fcef9d09ee7b2201004e34aa11e8cfab7708e781feba95e6a91f
data/.gitignore ADDED
@@ -0,0 +1,17 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in capistrano-logtail.gemspec
4
+ gemspec
data/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015 Jan Kmet
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
data/README.md ADDED
@@ -0,0 +1,41 @@
1
+ [![Code Climate](https://codeclimate.com/github/jankmet/capistrano-spy/badges/gpa.svg)](https://codeclimate.com/github/jankmet/capistrano-spy)
2
+
3
+ # capistrano-spy
4
+
5
+ viewing remote configurations and running services for capistrano
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile:
10
+
11
+ ```ruby
12
+ gem 'capistrano-spy'
13
+ ```
14
+
15
+ And then execute:
16
+
17
+ $ bundle
18
+
19
+ Or install it yourself as:
20
+
21
+ $ gem install capistrano-spy
22
+
23
+
24
+ ## Usage
25
+
26
+ Require in `Capfile`:
27
+
28
+ ```ruby
29
+ require 'capistrano/spy'
30
+ ```
31
+
32
+ This will add the following tasks:
33
+ * show:config[]
34
+ * show:running[]
35
+ * show:yml
36
+
37
+ ### Examples:
38
+
39
+ $ cap production show:yml
40
+ $ cap production show:config[app]
41
+ $ cap production show:running[unicorn]
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require 'bundler/gem_tasks'
@@ -0,0 +1,25 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'capistrano/spy/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "capistrano-spy"
8
+ spec.version = Capistrano::Spy::VERSION
9
+ spec.authors = ["Jan Kmet"]
10
+ spec.email = ["jan.kmet@gmail.com"]
11
+ spec.description = %q{viewing remote configurations and running services for capistrano}
12
+ spec.summary = %q{viewing remote configurations and running services for capistrano}
13
+ spec.homepage = ""
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files`.split($/)
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_dependency 'capistrano', '>= 3.0.0', '< 4.0.0'
22
+
23
+ spec.add_development_dependency 'bundler', '~> 1.3'
24
+ spec.add_development_dependency 'rake'
25
+ end
@@ -0,0 +1,38 @@
1
+ namespace :show do
2
+ desc "list all yml config files"
3
+ task :yml do
4
+ on roles(:app) do
5
+ with_debug_verbosity do
6
+ execute "ls #{shared_path}/config/*.yml"
7
+ end
8
+ end
9
+ end
10
+
11
+ desc "show shared config yml file"
12
+ task :config, [:file] do |_task, args|
13
+ on roles(:app) do
14
+ with_debug_verbosity do
15
+ execute "cat #{shared_path}/config/#{args.file}.yml"
16
+ end
17
+ end
18
+ end
19
+
20
+ desc "show running processes of service"
21
+ task :running, [:service] do |_task, args|
22
+ on roles(:app) do
23
+ with_debug_verbosity do
24
+ execute "ps aux | grep #{args.service}"
25
+ end
26
+ end
27
+ end
28
+ end
29
+
30
+ def with_debug_verbosity
31
+ output_verbosity = SSHKit.config.output_verbosity
32
+ begin
33
+ SSHKit.config.output_verbosity = Logger::DEBUG
34
+ yield
35
+ ensure
36
+ SSHKit.config.output_verbosity = output_verbosity
37
+ end
38
+ end
@@ -0,0 +1,8 @@
1
+ # Capistrano
2
+ module Capistrano
3
+ # Spy
4
+ module Spy
5
+ # gem version
6
+ VERSION = '0.1.4'
7
+ end
8
+ end
@@ -0,0 +1 @@
1
+ load File.expand_path('../spy/tasks/spy.cap', __FILE__)
@@ -0,0 +1 @@
1
+
data/lib/stalker.rb ADDED
@@ -0,0 +1 @@
1
+ load File.expand_path('../stalker/tasks/stalker.cap', __FILE__)
metadata ADDED
@@ -0,0 +1,104 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: capistrano-spy
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.4
5
+ platform: ruby
6
+ authors:
7
+ - Jan Kmet
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-05-27 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: capistrano
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 3.0.0
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: 4.0.0
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: 3.0.0
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: 4.0.0
33
+ - !ruby/object:Gem::Dependency
34
+ name: bundler
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '1.3'
40
+ type: :development
41
+ prerelease: false
42
+ version_requirements: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - "~>"
45
+ - !ruby/object:Gem::Version
46
+ version: '1.3'
47
+ - !ruby/object:Gem::Dependency
48
+ name: rake
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - ">="
59
+ - !ruby/object:Gem::Version
60
+ version: '0'
61
+ description: viewing remote configurations and running services for capistrano
62
+ email:
63
+ - jan.kmet@gmail.com
64
+ executables: []
65
+ extensions: []
66
+ extra_rdoc_files: []
67
+ files:
68
+ - ".gitignore"
69
+ - Gemfile
70
+ - LICENSE
71
+ - README.md
72
+ - Rakefile
73
+ - capistrano-spy.gemspec
74
+ - lib/capistrano-spy.rb
75
+ - lib/capistrano/spy.rb
76
+ - lib/capistrano/spy/tasks/spy.cap
77
+ - lib/capistrano/spy/version.rb
78
+ - lib/stalker.rb
79
+ homepage: ''
80
+ licenses:
81
+ - MIT
82
+ metadata: {}
83
+ post_install_message:
84
+ rdoc_options: []
85
+ require_paths:
86
+ - lib
87
+ required_ruby_version: !ruby/object:Gem::Requirement
88
+ requirements:
89
+ - - ">="
90
+ - !ruby/object:Gem::Version
91
+ version: '0'
92
+ required_rubygems_version: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ requirements: []
98
+ rubyforge_project:
99
+ rubygems_version: 2.4.6
100
+ signing_key:
101
+ specification_version: 4
102
+ summary: viewing remote configurations and running services for capistrano
103
+ test_files: []
104
+ has_rdoc: