Class: Kuby::Plugin
- Inherits:
-
Object
- Object
- Kuby::Plugin
- Defined in:
- lib/kuby/plugin.rb
Direct Known Subclasses
Kuby::Plugins::NginxIngress, Kuby::Plugins::RailsApp::Assets, Kuby::Plugins::RailsApp::CRDB::Plugin, Kuby::Plugins::RailsApp::Plugin, Kuby::Plugins::RailsApp::Sqlite, Kuby::Plugins::System
Instance Attribute Summary collapse
-
#environment ⇒ Object
readonly
Returns the value of attribute environment.
Class Method Summary collapse
- .dependencies ⇒ Object
- .depends_on(dependable_name, *constraints) ⇒ Object
-
.task_dirs ⇒ Object
returns an array of directories containing .rake files.
Instance Method Summary collapse
-
#after_configuration ⇒ Object
called after all plugins have been configured.
-
#after_deploy(manifest) ⇒ Object
called after deploying all resources.
-
#after_setup ⇒ Object
called after all plugins have been setup.
-
#before_deploy(manifest) ⇒ Object
called before deploying any resources.
-
#before_setup ⇒ Object
called before any plugins have been setup.
- #configure(&block) ⇒ Object
-
#docker_images ⇒ Object
additional docker images that should be built and pushed.
-
#initialize(environment) ⇒ Plugin
constructor
A new instance of Plugin.
-
#remove ⇒ Object
remove all global resources installed by #setup.
-
#resources ⇒ Object
additional kubernetes resources that should be deployed.
-
#setup ⇒ Object
install any global resources like operators, etc.
Constructor Details
#initialize(environment) ⇒ Plugin
Returns a new instance of Plugin.
7 8 9 10 |
# File 'lib/kuby/plugin.rb', line 7 def initialize(environment) @environment = environment after_initialize end |
Instance Attribute Details
#environment ⇒ Object (readonly)
Returns the value of attribute environment.
5 6 7 |
# File 'lib/kuby/plugin.rb', line 5 def environment @environment end |
Class Method Details
.dependencies ⇒ Object
22 23 24 |
# File 'lib/kuby/plugin.rb', line 22 def dependencies @dependencies ||= [] end |
.depends_on(dependable_name, *constraints) ⇒ Object
18 19 20 |
# File 'lib/kuby/plugin.rb', line 18 def depends_on(dependable_name, *constraints) dependencies << Kuby::Dependency.new(dependable_name, *constraints) end |
.task_dirs ⇒ Object
returns an array of directories containing .rake files
14 15 16 |
# File 'lib/kuby/plugin.rb', line 14 def task_dirs [] end |
Instance Method Details
#after_configuration ⇒ Object
called after all plugins have been configured
52 53 54 |
# File 'lib/kuby/plugin.rb', line 52 def after_configuration # do nothing by default end |
#after_deploy(manifest) ⇒ Object
called after deploying all resources
72 73 74 |
# File 'lib/kuby/plugin.rb', line 72 def after_deploy(manifest) # do nothing by default end |
#after_setup ⇒ Object
called after all plugins have been setup
62 63 64 |
# File 'lib/kuby/plugin.rb', line 62 def after_setup # do nothing by default end |
#before_deploy(manifest) ⇒ Object
called before deploying any resources
67 68 69 |
# File 'lib/kuby/plugin.rb', line 67 def before_deploy(manifest) # do nothing by default end |
#before_setup ⇒ Object
called before any plugins have been setup
57 58 59 |
# File 'lib/kuby/plugin.rb', line 57 def before_setup # do nothing by default end |
#configure(&block) ⇒ Object
27 28 29 |
# File 'lib/kuby/plugin.rb', line 27 def configure(&block) # do nothing by default end |
#docker_images ⇒ Object
additional docker images that should be built and pushed
47 48 49 |
# File 'lib/kuby/plugin.rb', line 47 def docker_images [] end |
#remove ⇒ Object
remove all global resources installed by #setup
37 38 39 |
# File 'lib/kuby/plugin.rb', line 37 def remove # do nothing by default end |
#resources ⇒ Object
additional kubernetes resources that should be deployed
42 43 44 |
# File 'lib/kuby/plugin.rb', line 42 def resources [] end |
#setup ⇒ Object
install any global resources like operators, etc
32 33 34 |
# File 'lib/kuby/plugin.rb', line 32 def setup # do nothing by default end |