diff --git a/app/models/wds_server.rb b/app/models/wds_server.rb index 5abf7934bf5bb15b8077159eb6fda24530accbe5..42992eb57082a5d733aae6e9e73c799f166673dd 100644 --- a/app/models/wds_server.rb +++ b/app/models/wds_server.rb @@ -79,7 +79,7 @@ class WdsServer < ApplicationRecord ensure_unattend(host) connection.shell(:powershell) do |sh| - # New-WdsClient -DeviceID '#{host.mac.upcase.delete ':'}' -DeviceName '#{host.name}' -WdsClientUnattend '#{unattend_file(host)}' -BootImagePath 'boot\\#{wdsify_architecture(host.architecture)}\\images\\#{(host.wds_boot_image || boot_images.first).file_name}' -PxePromptPolicy 'NoPrompt' + sh.run("New-WdsClient -DeviceID '#{host.mac.upcase.delete ':'}' -DeviceName '#{host.name}' -WdsClientUnattend '#{unattend_file(host)}' -BootImagePath 'boot\\#{wdsify_architecture(host.architecture)}\\images\\#{(host.wds_boot_image || boot_images.first).file_name}' -PxePromptPolicy 'NoPrompt'") end end