Sha256: f75b7cfd8ad8961e4cc031f71d721733a232c16f669f02c56176b5af45763289

Contents?: true

Size: 605 Bytes

Versions: 109

Compression:

Stored size: 605 Bytes

Contents

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

    def build(os_image_path)
      environment.prepare_build
      runner.configure_and_apply(collection.operating_system_stages)
      archive_handler.compress(environment.chroot_dir, os_image_path)
    end

    private

    attr_reader :environment, :collection, :runner, :archive_handler
  end
end

Version data entries

109 entries across 109 versions & 1 rubygems

Version Path
bosh-stemcell-1.2669.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2657.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2652.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2641.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2640.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2624.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2619.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2611.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2606.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2605.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2603.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2597.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2596.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2583.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2579.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2578.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2577.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2576.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2560.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2559.0 lib/bosh/stemcell/os_image_builder.rb