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.2809.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2807.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2801.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2798.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2797.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2792.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2789.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2788.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2787.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2786.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2785.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2781.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2780.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2778.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2776.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2768.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2765.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2754.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2751.0 lib/bosh/stemcell/os_image_builder.rb
bosh-stemcell-1.2749.0 lib/bosh/stemcell/os_image_builder.rb