-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Speed up startup by delayed loading (#32)
* Speed up startup by delayed loading * Fix spec requires
- Loading branch information
Showing
15 changed files
with
29 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,4 @@ | ||
require_relative 'master/create_command' | ||
require_relative 'master/terminate_command' | ||
|
||
class Kontena::Plugin::DigitalOcean::MasterCommand < Kontena::Command | ||
|
||
subcommand "create", "Create a new master to DigitalOcean", Kontena::Plugin::DigitalOcean::Master::CreateCommand | ||
subcommand "terminate", "Terminate DigitalOcean master", Kontena::Plugin::DigitalOcean::Master::TerminateCommand | ||
|
||
def execute | ||
end | ||
subcommand "create", "Create a new master to DigitalOcean", load_subcommand('kontena/plugin/digital_ocean/master/create_command') | ||
subcommand "terminate", "Terminate DigitalOcean master", load_subcommand('kontena/plugin/digital_ocean/master/terminate_command') | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,5 @@ | ||
require_relative 'nodes/create_command' | ||
require_relative 'nodes/restart_command' | ||
require_relative 'nodes/terminate_command' | ||
|
||
class Kontena::Plugin::DigitalOcean::NodeCommand < Kontena::Command | ||
|
||
subcommand "create", "Create a new node to DigitalOcean", Kontena::Plugin::DigitalOcean::Nodes::CreateCommand | ||
subcommand "restart", "Restart DigitalOcean node", Kontena::Plugin::DigitalOcean::Nodes::RestartCommand | ||
subcommand "terminate", "Terminate DigitalOcean node", Kontena::Plugin::DigitalOcean::Nodes::TerminateCommand | ||
|
||
def execute | ||
end | ||
subcommand "create", "Create a new node to DigitalOcean", load_subcommand('kontena/plugin/digital_ocean/nodes/create_command') | ||
subcommand "restart", "Restart DigitalOcean node", load_subcommand('kontena/plugin/digital_ocean/nodes/restart_command') | ||
subcommand "terminate", "Terminate DigitalOcean node", load_subcommand('kontena/plugin/digital_ocean/nodes/terminate_command') | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,4 @@ | ||
require_relative 'digital_ocean/master_command' | ||
require_relative 'digital_ocean/node_command' | ||
|
||
class Kontena::Plugin::DigitalOceanCommand < Kontena::Command | ||
|
||
subcommand 'master', 'DigitalOcean master related commands', Kontena::Plugin::DigitalOcean::MasterCommand | ||
subcommand 'node', 'DigitalOcean node related commands', Kontena::Plugin::DigitalOcean::NodeCommand | ||
|
||
def execute | ||
end | ||
subcommand 'master', 'DigitalOcean master related commands', load_subcommand('kontena/plugin/digital_ocean/master_command') | ||
subcommand 'node', 'DigitalOcean node related commands', load_subcommand('kontena/plugin/digital_ocean/node_command') | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
require 'kontena_cli' | ||
require_relative 'kontena/plugin/digital_ocean' | ||
require_relative 'kontena/plugin/digital_ocean_command' | ||
require 'kontena/plugin/digital_ocean' | ||
require 'kontena/cli/subcommand_loader' | ||
|
||
Kontena::MainCommand.register("digitalocean", "DigitalOcean specific commands", Kontena::Plugin::DigitalOceanCommand) | ||
Kontena::MainCommand.register("digitalocean", "DigitalOcean specific commands", Kontena::Cli::SubcommandLoader.new('kontena/plugin/digital_ocean_command')) |
2 changes: 1 addition & 1 deletion
2
spec/kontena/plugin/digital_ocean/master/create_command_spec.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
spec/kontena/plugin/digital_ocean/master/terminate_command_spec.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
spec/kontena/plugin/digital_ocean/nodes/terminate_command_spec.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters