mirror of https://github.com/docker/docs.git
Only offer to migrate if requirements are met
Signed-off-by: Jeffrey Morgan <jmorganca@gmail.com>
This commit is contained in:
parent
a3064d24cc
commit
05ca1fc9a7
|
|
@ -2,7 +2,7 @@
|
||||||
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
|
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
|
||||||
|
|
||||||
#define MyAppName "Docker Toolbox"
|
#define MyAppName "Docker Toolbox"
|
||||||
#define MyAppVersion "1.8.0"
|
#define MyAppVersion "1.8.0b"
|
||||||
#define MyAppPublisher "Docker"
|
#define MyAppPublisher "Docker"
|
||||||
#define MyAppURL "https://docker.com"
|
#define MyAppURL "https://docker.com"
|
||||||
#define MyAppContact "https://docs.docker.com"
|
#define MyAppContact "https://docs.docker.com"
|
||||||
|
|
@ -305,6 +305,12 @@ function MigrateVM() : Boolean;
|
||||||
var
|
var
|
||||||
ResultCode: Integer;
|
ResultCode: Integer;
|
||||||
begin
|
begin
|
||||||
|
if not FileExists('C:\Program Files\Oracle\VirtualBox\VBoxManage.exe') or not FileExists(ExpandConstant('{app}\docker-machine.exe')) then
|
||||||
|
begin
|
||||||
|
Result := true
|
||||||
|
exit
|
||||||
|
end;
|
||||||
|
|
||||||
ExecAsOriginalUser('C:\Program Files\Oracle\VirtualBox\VBoxManage.exe', 'showvminfo default', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
|
ExecAsOriginalUser('C:\Program Files\Oracle\VirtualBox\VBoxManage.exe', 'showvminfo default', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
|
||||||
if ResultCode <> 1 then
|
if ResultCode <> 1 then
|
||||||
begin
|
begin
|
||||||
|
|
@ -364,9 +370,7 @@ begin
|
||||||
if IsTaskSelected(taskname) then
|
if IsTaskSelected(taskname) then
|
||||||
ModPath();
|
ModPath();
|
||||||
|
|
||||||
migrationSuccess:= true
|
migrationSuccess:= MigrateVM();
|
||||||
if IsComponentSelected('DockerMachine') then
|
|
||||||
migrationSuccess := MigrateVM();
|
|
||||||
|
|
||||||
if migrationSuccess then
|
if migrationSuccess then
|
||||||
begin
|
begin
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue