Class: Lono::Seed
- Inherits:
-
Object
- Object
- Lono::Seed
- Includes:
- Blueprint::Root, Conventions
- Defined in:
- lib/lono/seed/base.rb,
lib/lono/seed.rb
Overview
Subclasses should implement:
variables - Returns String with content of varibles files.
setup - Hook to do extra things like create IAM service roles.
finish - Finish hook after config files have been created.
Note there is no params method to hook. The Base class handles params well.
Defined Under Namespace
Instance Method Summary collapse
- #create ⇒ Object
-
#initialize(blueprint, options = {}) ⇒ Seed
constructor
A new instance of Seed.
Methods included from Conventions
Methods included from Blueprint::Root
#bundler_groups, #find_blueprint_root, #require_bundle_gems, #set_blueprint_root
Constructor Details
#initialize(blueprint, options = {}) ⇒ Seed
Returns a new instance of Seed.
6 7 8 9 10 |
# File 'lib/lono/seed.rb', line 6 def initialize(blueprint, ={}) @blueprint, @options = blueprint, set_blueprint_root(@blueprint) @template, @param = template_param_convention() end |
Instance Method Details
#create ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/lono/seed.rb', line 12 def create puts "Creating starter config files for #{@blueprint}" configs_class = load_configs_class # ::Configs or Lono::Seed::Base configs = configs_class.new(@blueprint, @options) # The Configs class implements: variables configs.run # setup the instance variables end |