kplay 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/exe/kplay +0 -1
- data/lib/kplay.rb +1 -0
- data/lib/kplay/config.rb +2 -1
- data/lib/kplay/pod.rb +5 -0
- data/lib/kplay/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 515860b760fb32f630f8de69febfae4d21a1b682fd7b7930390656c9cab9a927
|
4
|
+
data.tar.gz: 39e66a13e481351ab4b9e0b232de6469d1600c9f2a7443a390a41f4b5ac31f27
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7783d816fb7bece2a39ac02697a26d165ff5fc9e09cb38c32df6174d6663d6d7ce3f9a6775217a3b0a2dabbea15f43d3454c277418c34e16a5f3a1826e76e89f
|
7
|
+
data.tar.gz: 85c90bdebec4dab9bb3a0cbf0d38e5581e6e8f6fec652b1e11535313d93c80fccb16e2bd6e1e1175aee0862dc8e9c1ffb58ff6c384e82c1f46c0b2b94db21bcc
|
data/exe/kplay
CHANGED
data/lib/kplay.rb
CHANGED
data/lib/kplay/config.rb
CHANGED
@@ -12,7 +12,8 @@ module Kplay
|
|
12
12
|
'mount_path' => '/${name}',
|
13
13
|
'shell' => '/bin/bash',
|
14
14
|
'shell_args' => ['-c', 'cd /${name}; exec "${SHELL:-sh}"'],
|
15
|
-
'stop_grace_period' => 5
|
15
|
+
'stop_grace_period' => 5,
|
16
|
+
'etc_hosts' => [] # <ip> <alias1> [<alias2> ...]
|
16
17
|
}.freeze
|
17
18
|
|
18
19
|
attr_reader :path, :data
|
data/lib/kplay/pod.rb
CHANGED
@@ -34,11 +34,16 @@ module Kplay
|
|
34
34
|
# @return [Hash]
|
35
35
|
#
|
36
36
|
def configuration
|
37
|
+
host_aliases = config[:etc_hosts].map do |host|
|
38
|
+
ip, *hostnames = host.strip.split(' ')
|
39
|
+
{ 'ip' => ip, 'hostnames' => hostnames }
|
40
|
+
end
|
37
41
|
{
|
38
42
|
'apiVersion' => 'v1',
|
39
43
|
'kind' => 'Pod',
|
40
44
|
'metadata' => { 'name' => name },
|
41
45
|
'spec' => {
|
46
|
+
'hostAliases' => host_aliases,
|
42
47
|
'containers' => [
|
43
48
|
{
|
44
49
|
'name' => name,
|
data/lib/kplay/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kplay
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alex Kukushkin
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|
@@ -145,7 +145,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
145
145
|
version: '0'
|
146
146
|
requirements: []
|
147
147
|
rubyforge_project:
|
148
|
-
rubygems_version: 2.
|
148
|
+
rubygems_version: 2.7.6
|
149
149
|
signing_key:
|
150
150
|
specification_version: 4
|
151
151
|
summary: Starts your project within a container in minikube
|