Module: Pipely::Build
- Defined in:
- lib/pipely/build.rb,
lib/pipely/build/template.rb,
lib/pipely/build/definition.rb,
lib/pipely/build/daily_scheduler.rb,
lib/pipely/build/s3_path_builder.rb,
lib/pipely/build/template_helpers.rb,
lib/pipely/build/environment_config.rb,
lib/pipely/build/right_now_scheduler.rb
Overview
Turn Templates+config into a deployable Definition.
Defined Under Namespace
Modules: TemplateHelpers Classes: DailyScheduler, Definition, EnvironmentConfig, RightNowScheduler, S3PathBuilder, Template
Class Method Summary collapse
Class Method Details
.build_definition(template, environment, config_path) ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/pipely/build.rb', line 14 def self.build_definition(template, environment, config_path) env = environment.to_sym config = EnvironmentConfig.load(config_path, env) case environment.to_sym when :production s3_prefix = "production/#{config[:namespace]}" scheduler = DailyScheduler.new when :staging s3_prefix = "staging/#{`whoami`.strip}/#{config[:namespace]}" scheduler = RightNowScheduler.new end Definition.new(template, env, s3_prefix, scheduler, config) end |