kontena-plugin-aws 0.3.0 → 0.3.1

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
- SHA1:
3
- metadata.gz: 55b29eae013f8fdb511459a7161f69bbf7496bf7
4
- data.tar.gz: d1a71a0d1196d38561efc7d694d90c1c83747161
2
+ SHA256:
3
+ metadata.gz: 4531cb5a9f6cb48e66422a32fd82d51dd9a80dc565face3de94893977924eef6
4
+ data.tar.gz: 1d31821c4ce47c9666bdbb43beaf6b723a8d7c4902c4fb00c3f4e81e4a5e563a
5
5
  SHA512:
6
- metadata.gz: 62546682ef22aa0f6a68a250de5053f7fa4f5d769b8cddb5fc984f7d503bbd854417f6ff7c2681ca37b7c25f6a22cca164ad710c38101db00a7b1a3d62dd07f0
7
- data.tar.gz: ee535e54411ea745dd336c65938be782039e3d2981df1428106936ddee685cb3c4b06ae0aa2445233b230adbeb9af2a44421041abce4e6ee059409578c342205
6
+ metadata.gz: 86ea8c38bf51bc71691c4d67dac2a14d30ef1c21c5e4e27f1de80f688ed066404ae46eef8577757943e9dc4a78c7f9035d118b8cfab7b77d558fa2625a5c5ec3
7
+ data.tar.gz: 77a357bc3d5ca6594797992e694f3327cee98b824adb0ebac6a1b2ac507af5a6acc1132066f370f2c49a812bba737005c6df9135138d8b8db915d845f273f95c
@@ -1,5 +1,4 @@
1
- require 'securerandom'
2
- require_relative '../prompts'
1
+ require 'kontena/plugin/aws/prompts'
3
2
 
4
3
  module Kontena::Plugin::Aws::Master
5
4
  class CreateCommand < Kontena::Command
@@ -16,7 +15,8 @@ module Kontena::Plugin::Aws::Master
16
15
  option "--mongodb-uri", "URI", "External MongoDB uri (optional)"
17
16
 
18
17
  def execute
19
- require_relative '../../../machine/aws'
18
+ require 'securerandom'
19
+ require 'kontena/machine/aws'
20
20
 
21
21
  provisioner.run!(
22
22
  name: name,
@@ -1,3 +1,5 @@
1
+ require 'kontena/plugin/aws/prompts'
2
+
1
3
  module Kontena::Plugin::Aws::Master
2
4
  class TerminateCommand < Kontena::Command
3
5
  include Kontena::Cli::Common
@@ -1,11 +1,4 @@
1
- require_relative 'master/create_command'
2
- require_relative 'master/terminate_command'
3
-
4
1
  class Kontena::Plugin::Aws::MasterCommand < Kontena::Command
5
-
6
- subcommand "create", "Create a new master to AWS", Kontena::Plugin::Aws::Master::CreateCommand
7
- subcommand "terminate", "Destroy current master from AWS", Kontena::Plugin::Aws::Master::TerminateCommand
8
-
9
- def execute
10
- end
2
+ subcommand "create", "Create a new master to AWS", load_subcommand('kontena/plugin/aws/master/create_command')
3
+ subcommand "terminate", "Destroy current master from AWS", load_subcommand('kontena/plugin/aws/master/terminate_command')
11
4
  end
@@ -1,13 +1,5 @@
1
- require_relative 'nodes/create_command'
2
- require_relative 'nodes/restart_command'
3
- require_relative 'nodes/terminate_command'
4
-
5
1
  class Kontena::Plugin::Aws::NodeCommand < Kontena::Command
6
-
7
- subcommand "create", "Create a new node to AWS", Kontena::Plugin::Aws::Nodes::CreateCommand
8
- subcommand "restart", "Restart AWS node", Kontena::Plugin::Aws::Nodes::RestartCommand
9
- subcommand "terminate", "Terminate AWS node", Kontena::Plugin::Aws::Nodes::TerminateCommand
10
-
11
- def execute
12
- end
2
+ subcommand "create", "Create a new node to AWS", load_subcommand('kontena/plugin/aws/nodes/create_command')
3
+ subcommand "restart", "Restart AWS node", load_subcommand('kontena/plugin/aws/nodes/restart_command')
4
+ subcommand "terminate", "Terminate AWS node", load_subcommand('kontena/plugin/aws/nodes/terminate_command')
13
5
  end
@@ -1,3 +1,5 @@
1
+ require 'kontena/plugin/aws/prompts'
2
+
1
3
  module Kontena::Plugin::Aws::Nodes
2
4
  class CreateCommand < Kontena::Command
3
5
  include Kontena::Cli::Common
@@ -1,3 +1,5 @@
1
+ require 'kontena/plugin/aws/prompts'
2
+
1
3
  module Kontena::Plugin::Aws::Nodes
2
4
  class RestartCommand < Kontena::Command
3
5
  include Kontena::Cli::Common
@@ -1,3 +1,5 @@
1
+ require 'kontena/plugin/aws/prompts'
2
+
1
3
  module Kontena::Plugin::Aws::Nodes
2
4
  class TerminateCommand < Kontena::Command
3
5
  include Kontena::Cli::Common
@@ -28,11 +28,11 @@ module Kontena::Plugin::Aws::Prompts
28
28
 
29
29
  module Defaults
30
30
  def default_access_key
31
- prompt.ask('AWS access key:', echo: false)
31
+ prompt.mask('AWS access key:')
32
32
  end
33
33
 
34
34
  def default_secret_key
35
- prompt.ask('AWS secret key:', echo: false)
35
+ prompt.mask('AWS secret key:')
36
36
  end
37
37
 
38
38
  CREATE_KEYPAIR_TEXT = 'Create new key pair'
@@ -1,7 +1,7 @@
1
1
  module Kontena
2
2
  module Plugin
3
3
  module Aws
4
- VERSION = "0.3.0"
4
+ VERSION = "0.3.1"
5
5
  end
6
6
  end
7
7
  end
@@ -1,11 +1,4 @@
1
- require_relative 'aws/master_command'
2
- require_relative 'aws/node_command'
3
-
4
1
  class Kontena::Plugin::AwsCommand < Kontena::Command
5
-
6
- subcommand 'master', 'AWS master related commands', Kontena::Plugin::Aws::MasterCommand
7
- subcommand 'node', 'AWS node related commands', Kontena::Plugin::Aws::NodeCommand
8
-
9
- def execute
10
- end
2
+ subcommand 'master', 'AWS master related commands', load_subcommand('kontena/plugin/aws/master_command')
3
+ subcommand 'node', 'AWS node related commands', load_subcommand('kontena/plugin/aws/node_command')
11
4
  end
@@ -1,5 +1,5 @@
1
1
  require 'kontena_cli'
2
2
  require_relative 'kontena/plugin/aws'
3
- require_relative 'kontena/plugin/aws_command'
3
+ require 'kontena/cli/subcommand_loader'
4
4
 
5
- Kontena::MainCommand.register("aws", "AWS specific commands", Kontena::Plugin::AwsCommand)
5
+ Kontena::MainCommand.register("aws", "AWS specific commands", Kontena::Cli::SubcommandLoader.new('kontena/plugin/aws_command'))
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kontena-plugin-aws
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kontena, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-02 00:00:00.000000000 Z
11
+ date: 2017-11-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: kontena-cli
@@ -128,7 +128,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
128
128
  version: '0'
129
129
  requirements: []
130
130
  rubyforge_project:
131
- rubygems_version: 2.4.5
131
+ rubygems_version: 2.7.1
132
132
  signing_key:
133
133
  specification_version: 4
134
134
  summary: Kontena AWS plugin