vidar 0.10.2 → 0.11.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5c32abc93901180e156ad0a5f1e8c6dffec9290e23e413cadd8fff019cb6e51c
4
- data.tar.gz: 16246d8c98b35ec531ac1f3e10eb95982046ee475bb7f1cf9aa5fb1088d7a259
3
+ metadata.gz: 5679fe9c0628ba2bda1ba1ea67e3d6a03fb904d3efac60469e87b5eafbc53305
4
+ data.tar.gz: 31e5e63195717afb6a22e1b5650efcf762aedd65e10fd97b1de712aaa7adaf95
5
5
  SHA512:
6
- metadata.gz: 441153a2ed103dec08b12529b811f1a4fedf2239822a189c1d1a8e0c54c9677b3cec876a1ea9598e89927d5263e9084912db97a3e5cf296dc06085d6f3fd44d5
7
- data.tar.gz: 4a69ba6b2cca2af3ee06aefcfa0f833b55c7ae65d81e2248503e23186a4a5b1cae1fed4934a21f9649f82b5ae2b9bafc8636436bf3ccc406760271141f66e7bc
6
+ metadata.gz: e31cb15a1b95ac839a7942c9dc01a69132ee51195df788b2fbf8b5d1f66d56799c83a4c680f6d5974e0b88d72885ef48885cfb28d81fa03f4c53c07c3a310a2e
7
+ data.tar.gz: 4e76a3722633e592acb909c9d87e00ae9ae62011b7331e6ef65a93543d42c15405f660e2731c67173d76e85482ad3eb72255b33137cd87489892c53737bd18ab
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- vidar (0.10.2)
4
+ vidar (0.11.0)
5
5
  colorize
6
6
  faraday
7
7
  thor (~> 0.20)
data/lib/vidar/cli.rb CHANGED
@@ -134,7 +134,7 @@ module Vidar
134
134
  end
135
135
 
136
136
  desc "kube_exec", "Execute given command in the first running pod"
137
- method_option :command, default: "/bin/sh"
137
+ method_option :command
138
138
  method_option :name, required: false
139
139
  def kube_exec
140
140
  Log.info "Current kubectl context: #{Config.get!(:kubectl_context)}"
@@ -164,7 +164,14 @@ module Vidar
164
164
  method_option :command, required: false
165
165
  method_option :name, required: false
166
166
  def console
167
- invoke :kube_exec, name: options[:name], command: options[:command] || Config.get!(:console_command)
167
+ invoke :kube_exec, [], name: options[:name], command: options[:command] || Config.get!(:console_command)
168
+ end
169
+
170
+ desc "ssh", "Execute shell command in the first running pod"
171
+ method_option :command, required: false
172
+ method_option :name, required: false
173
+ def ssh
174
+ invoke :kube_exec, [], name: options[:name], command: options[:command] || Config.get!(:shell_command)
168
175
  end
169
176
 
170
177
  method_option :revision, required: false
data/lib/vidar/config.rb CHANGED
@@ -9,6 +9,7 @@ module Vidar
9
9
  revision: -> { `git rev-parse HEAD`.strip },
10
10
  revision_name: -> { `git show --pretty=format:"%s (%h)" -s HEAD`.strip },
11
11
  kubectl_context: -> { `kubectl config current-context`.strip },
12
+ shell_command: -> { "/bin/sh" },
12
13
  console_command: -> { "bin/console" },
13
14
  }.freeze
14
15
 
data/lib/vidar/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Vidar
2
- VERSION = '0.10.2'.freeze
2
+ VERSION = '0.11.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vidar
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.2
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Krzysztof Knapik
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2019-11-20 00:00:00.000000000 Z
12
+ date: 2019-11-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: colorize