Class: Migrant::Provisioners::Base
- Inherits:
-
Object
- Object
- Migrant::Provisioners::Base
- Defined in:
- lib/migrant/provisioners/base.rb
Direct Known Subclasses
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(env) ⇒ Base
constructor
A new instance of Base.
-
#prepare ⇒ Object
Any pre-provisioning preparation.
-
#run ⇒ Object
Run the provisioner.
-
#upload ⇒ Object
Upload any necessary files.
Constructor Details
#initialize(env) ⇒ Base
Returns a new instance of Base.
13 14 15 |
# File 'lib/migrant/provisioners/base.rb', line 13 def initialize(env) @environment = env end |
Class Method Details
.register(shortcut) ⇒ Object
4 5 6 7 |
# File 'lib/migrant/provisioners/base.rb', line 4 def self.register(shortcut) @@provisioners ||= {} @@provisioners[shortcut] = self end |
.registered(shortcut) ⇒ Object
9 10 11 |
# File 'lib/migrant/provisioners/base.rb', line 9 def self.registered(shortcut) @@provisioners[shortcut] end |
Instance Method Details
#prepare ⇒ Object
Any pre-provisioning preparation
23 24 25 |
# File 'lib/migrant/provisioners/base.rb', line 23 def prepare raise "invalid provisioner" end |
#run ⇒ Object
Run the provisioner
28 29 30 |
# File 'lib/migrant/provisioners/base.rb', line 28 def run raise "invalide provisioner" end |
#upload ⇒ Object
Upload any necessary files
18 19 20 |
# File 'lib/migrant/provisioners/base.rb', line 18 def upload raise "invalid provisioner" end |