Sha256: 2317b8f7fcc642df6e244d93dba299a2614c53cfdebe44e29cb5228ae1723bdb

Contents?: true

Size: 752 Bytes

Versions: 15

Compression:

Stored size: 752 Bytes

Contents

require 'fileutils'
require 'bosh/stemcell/stage_collection'

module Bosh::Stemcell
  class StemcellBuilder
    def initialize(dependencies = {})
      @gem_components = dependencies.fetch(:gem_components)
      @environment = dependencies.fetch(:environment)
      @runner = dependencies.fetch(:runner)
      @collection = dependencies.fetch(:collection)
    end

    def build
      gem_components.build_release_gems
      environment.prepare_build

      stemcell_stages = collection.extract_operating_system_stages +
        collection.agent_stages +
        collection.build_stemcell_image_stages
      runner.configure_and_apply(stemcell_stages)
    end

    private

    attr_reader :gem_components, :environment, :collection, :runner
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
bosh-stemcell-1.2881.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2865.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2862.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2859.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2858.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2855.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2852.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2849.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2847.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2840.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2839.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2831.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2830.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2829.0 lib/bosh/stemcell/stemcell_builder.rb
bosh-stemcell-1.2827.0 lib/bosh/stemcell/stemcell_builder.rb