Sha256: d764448dae9030304d119f1f53939b2209c92468530f085a9232e33923ce8b4f

Contents?: true

Size: 1.54 KB

Versions: 6

Compression:

Stored size: 1.54 KB

Contents

module Veewee
  module Provider
    module Parallels
      module BoxCommand

        def build_info
          info=super
          command="prlctl --version"
          output=IO.popen("#{command}").readlines
          info << {:filename => ".parallels_version",:content => output[0].split(/ /)[2]}

        end

        # Determine the iso of the guest additions
        def guest_iso_path
          # So we begin by transferring the ISO file of the vmware tools

          # Set default
          iso_image="/Library/Parallels/Tools/prl-tools-lin.iso"
          iso_image="/Library/Parallels/Tools/prl-tools-mac.iso" if definition.os_type_id=~/^Darwin/
          iso_image="/Library/Parallels/Tools/prl-tools-win.iso" if definition.os_type_id=~/^Win/
          iso_image="/Library/Parallels/Tools/prl-tools-other.iso" if definition.os_type_id=~/^Free/
          iso_image="/Library/Parallels/Tools/prl-tools-other.iso" if definition.os_type_id=~/^Solaris/
          return iso_image

        end

        # Transfer information provide by the provider to the box
        #
        #
        def transfer_buildinfo(options)
          super(options)

          # When we get here, ssh is available and no postinstall scripts have been executed yet
          # So we begin by transferring the ISO file of the vmware tools

          ui.info "About to transfer parallels tools iso buildinfo to the box #{name} - #{ip_address} - #{ssh_options}"
          iso_image=guest_iso_path
          self.scp(iso_image,File.basename(iso_image))
        end

      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
veewee-0.3.1 lib/veewee/provider/parallels/box/helper/buildinfo.rb
veewee-0.3.0.beta2 lib/veewee/provider/parallels/box/helper/buildinfo.rb
veewee-0.3.0.beta1 lib/veewee/provider/parallels/box/helper/buildinfo.rb
veewee-0.3.0.alpha9 lib/veewee/provider/parallels/box/helper/buildinfo.rb
veewee-0.3.0.alpha8 lib/veewee/provider/parallels/box/helper/buildinfo.rb
veewee-0.3.0.alpha7 lib/veewee/provider/parallels/box/helper/buildinfo.rb