Class: VagrantPlugins::AVF::DriverPaths

Inherits:
Object
  • Object
show all
Defined in:
lib/vagrant_provider_avf/driver_paths.rb

Instance Method Summary collapse

Constructor Details

#initialize(machine_data_dir) ⇒ DriverPaths

Returns a new instance of DriverPaths.



6
7
8
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 6

def initialize(machine_data_dir)
  @machine_data_dir = Pathname.new(machine_data_dir)
end

Instance Method Details

#cleanup_paths(linux_cloud_init_seed_path:) ⇒ Object



52
53
54
55
56
57
58
59
60
61
62
63
64
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 52

def cleanup_paths(linux_cloud_init_seed_path:)
  [
    runtime_disk_path,
    linux_efi_variable_store_path,
    linux_cloud_init_seed_path,
    start_request_path,
    started_path,
    error_path,
    console_log_path,
    helper_log_path,
    helper_binary_path
  ]
end

#console_log_pathObject



38
39
40
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 38

def console_log_path
  @machine_data_dir.join("console.log")
end

#efi_variable_store_path_for(boot_config) ⇒ Object



46
47
48
49
50
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 46

def efi_variable_store_path_for(boot_config)
  return linux_efi_variable_store_path if boot_config.linux_disk_boot?

  nil
end

#error_pathObject



34
35
36
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 34

def error_path
  @machine_data_dir.join("avf-error.txt")
end

#helper_binary_pathObject



18
19
20
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 18

def helper_binary_path
  @machine_data_dir.join("avf-runner")
end

#helper_entitlements_pathObject



14
15
16
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 14

def helper_entitlements_path
  Pathname.new(File.expand_path("driver/virtualization.entitlements", __dir__))
end

#helper_log_pathObject



42
43
44
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 42

def helper_log_path
  @machine_data_dir.join("avf-helper.log")
end

#helper_source_pathObject



10
11
12
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 10

def helper_source_path
  Pathname.new(File.expand_path("driver/avf_runner.swift", __dir__))
end

#runtime_disk_pathObject



22
23
24
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 22

def runtime_disk_path
  @machine_data_dir.join("disk.img")
end

#start_request_pathObject



26
27
28
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 26

def start_request_path
  @machine_data_dir.join("avf-start-request.json")
end

#started_pathObject



30
31
32
# File 'lib/vagrant_provider_avf/driver_paths.rb', line 30

def started_path
  @machine_data_dir.join("avf-started.json")
end