Class: Veewee::Provider::Kvm::Box
- Includes:
- Core, Core::BoxCommand, Veewee::Provider::Kvm, BoxCommand
- Defined in:
- lib/veewee/provider/kvm/box.rb
Instance Attribute Summary collapse
-
#connection ⇒ Object
Returns the value of attribute connection.
Attributes inherited from Core::Box
#definition, #env, #name, #provider
Instance Method Summary collapse
-
#initialize(name, env) ⇒ Box
constructor
A new instance of Box.
Methods included from BoxCommand
#add_floppy, #add_virtio_drivers, #build, #console_type, #create, #create_server, #create_volume, #destroy, #destroy_vm, #destroy_volume, #exists?, #exists_vm?, #exists_volume?, #halt, #ip_address, #poweroff, #running?, #ssh_options, #stop, #up, #validate_kvm
Methods included from Core::BoxCommand
#build, #build_info, #copy_to_box, #create_floppy, #create_wget_vbs_command, #escape_and_echo, #exec, #fill_sequence, #filter_postinstall_files, #halt, #handle_kickstart, #handle_postinstall, #issh, #poweroff, #scp, #send_vnc_keycode, #ssh, #ssh_command_string, #string_to_vnccode, #sudo, #transfer_buildinfo, #validate_postinstall_regex, #validate_tags, #vnc_type, #wget_vbs, #wget_vbs_file, #wincp, #winrm, #winrm_command_string
Methods inherited from Core::Box
#gem_available?, #reload, #set_definition, #ui
Methods included from Core::Helper::Iso
#download_iso, #download_progress, #hashsum, #verify_iso, #verify_sum
Methods included from Core::Helper::Comm
#comm_execute, #comm_method, #comm_transfer_file, #when_comm_login_works
Methods included from Core::Helper::Ssh
#ssh_execute, #ssh_transfer_file, #when_ssh_login_works
Methods included from Core::Helper::Shell
Methods included from Core::Helper::Web
#allow_for_http_request, #server_for_http_request, #wait_for_http_request
Methods included from Core::Helper::Tcp
#execute_when_tcp_available, #get_local_ip, #guess_free_port, #host_ip_as_seen_by_guest, #is_tcp_port_open?
Constructor Details
#initialize(name, env) ⇒ Box
Returns a new instance of Box.
30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/veewee/provider/kvm/box.rb', line 30 def initialize(name,env) super(name,env) @connection=::Fog::Compute[:libvirt] # Many of the existing templates have disk_format set to "VDI" # Use "raw" instead as a Libvirt-compatible default definition.disk_format.downcase! definition.disk_format = "raw" if definition.disk_format == "vdi" @volume_name = "#{name}.#{definition.disk_format}" end |
Instance Attribute Details
#connection ⇒ Object
Returns the value of attribute connection.
28 29 30 |
# File 'lib/veewee/provider/kvm/box.rb', line 28 def connection @connection end |