mirror of
https://github.com/docker/docs.git
synced 2026-11-05 00:14:17 +03:00
Merge branch 'upgrade'
This commit is contained in:
@@ -18,33 +18,35 @@ RUN curl -fsSL https://github.com/mackyle/xar/archive/xar-1.6.1.tar.gz | tar xvz
|
||||
./autogen.sh && ./configure && \
|
||||
make && make install
|
||||
|
||||
ENV VBOX_VERSION 5.0.6
|
||||
ENV VBOX_REV 103037
|
||||
ENV VBOX_VERSION 5.0.8
|
||||
ENV VBOX_REV 103449
|
||||
|
||||
RUN curl -fsSL -o /vbox.dmg http://download.virtualbox.org/virtualbox/$VBOX_VERSION/VirtualBox-$VBOX_VERSION-$VBOX_REV-OSX.dmg \
|
||||
&& echo "$(curl -fsSL 'http://download.virtualbox.org/virtualbox/'"$VBOX_VERSION"'/SHA256SUMS' | awk '$2 ~ /-OSX.dmg$/ { print $1 }') */vbox.dmg" | sha256sum -c -
|
||||
|
||||
# Download the Docker parts
|
||||
|
||||
ENV DOCKER_VERSION 1.8.3
|
||||
RUN curl -fsSL -o /docker https://get.docker.com/builds/Darwin/x86_64/docker-$DOCKER_VERSION
|
||||
ENV DOCKER_VERSION 1.9.0-rc1
|
||||
RUN curl -fsSL -o /docker https://test.docker.com/builds/Darwin/x86_64/docker-$DOCKER_VERSION
|
||||
RUN chmod +x /docker
|
||||
|
||||
ENV DOCKER_MACHINE_VERSION 0.4.1
|
||||
RUN curl -fsSL -o /docker-machine https://github.com/docker/machine/releases/download/v$DOCKER_MACHINE_VERSION/docker-machine_darwin-amd64
|
||||
RUN chmod +x /docker-machine
|
||||
ENV DOCKER_MACHINE_VERSION 0.5.0-rc1
|
||||
RUN curl -fsSL -o /docker-machine.zip https://github.com/docker/machine/releases/download/v$DOCKER_MACHINE_VERSION/docker-machine_darwin-amd64.zip
|
||||
RUN 7z x /docker-machine.zip && rm -f /docker-machine.zip
|
||||
RUN chmod +x /docker-machine*
|
||||
|
||||
ENV DOCKER_COMPOSE_VERSION 1.4.2
|
||||
ENV DOCKER_COMPOSE_VERSION 1.5.0rc1
|
||||
RUN curl -fsSL -o /docker-compose https://github.com/docker/compose/releases/download/$DOCKER_COMPOSE_VERSION/docker-compose-Darwin-x86_64
|
||||
RUN chmod +x /docker-compose
|
||||
|
||||
ENV BOOT2DOCKER_ISO_VERSION $DOCKER_VERSION
|
||||
RUN curl -fsSL -o /boot2docker.iso https://github.com/boot2docker/boot2docker/releases/download/v$DOCKER_VERSION/boot2docker.iso
|
||||
# RUN curl -fsSL -o /boot2docker.iso https://github.com/boot2docker/boot2docker/releases/download/v$DOCKER_VERSION/boot2docker.iso
|
||||
RUN curl -fsSL -o /boot2docker.iso https://github.com/tianon/boot2docker-legacy/releases/download/v$DOCKER_VERSION/boot2docker.iso
|
||||
|
||||
ENV KITEMATIC_VERSION 0.8.7
|
||||
ENV KITEMATIC_VERSION 0.9.0
|
||||
RUN curl -fsSL -o /kitematic.zip https://github.com/kitematic/kitematic/releases/download/v$KITEMATIC_VERSION/Kitematic-$KITEMATIC_VERSION-Mac.zip
|
||||
|
||||
ENV INSTALLER_VERSION 1.8.3
|
||||
ENV INSTALLER_VERSION 1.9.0-rc1
|
||||
|
||||
ENV MIXPANEL_TOKEN c306ae65c33d7d09fe3e546f36493a6e
|
||||
|
||||
@@ -112,7 +114,7 @@ RUN cd /mpkg/dockermachine.pkg && \
|
||||
mkdir rootfs && \
|
||||
cd rootfs && \
|
||||
mkdir -p usr/local/bin && \
|
||||
mv /docker-machine usr/local/bin/ && \
|
||||
mv /docker-machine* usr/local/bin/ && \
|
||||
ls -al /usr/local/bin/ && \
|
||||
find . | cpio -o --format odc | gzip -c > ../Payload && \
|
||||
mkbom . ../Bom && \
|
||||
|
||||
@@ -17,21 +17,28 @@ RUN cd innosetup && \
|
||||
wine "./innounp.exe" -e "is-unicode.exe"
|
||||
|
||||
# installer components
|
||||
ENV INSTALLER_VERSION 1.8.3
|
||||
ENV DOCKER_VERSION 1.8.3
|
||||
ENV DOCKER_MACHINE_VERSION 0.4.1
|
||||
ENV INSTALLER_VERSION 1.9.0-rc1
|
||||
ENV DOCKER_VERSION 1.9.0-rc1
|
||||
ENV DOCKER_MACHINE_VERSION 0.5.0-rc2
|
||||
ENV BOOT2DOCKER_ISO_VERSION $DOCKER_VERSION
|
||||
ENV KITEMATIC_VERSION 0.8.7
|
||||
ENV VIRTUALBOX_VERSION 5.0.6
|
||||
ENV VIRTUALBOX_REVISION 103037
|
||||
ENV KITEMATIC_VERSION 0.9.0
|
||||
ENV VIRTUALBOX_VERSION 5.0.8
|
||||
ENV VIRTUALBOX_REVISION 103449
|
||||
ENV GIT_VERSION 2.5.0
|
||||
ENV MIXPANEL_TOKEN c306ae65c33d7d09fe3e546f36493a6e
|
||||
|
||||
RUN mkdir /bundle
|
||||
WORKDIR /bundle
|
||||
RUN curl -fsSL -o docker.exe "https://get.docker.com/builds/Windows/x86_64/docker-$DOCKER_VERSION.exe"
|
||||
RUN curl -fsSL -o docker-machine.exe "https://github.com/docker/machine/releases/download/v$DOCKER_MACHINE_VERSION/docker-machine_windows-amd64.exe"
|
||||
RUN curl -fsSL -o boot2docker.iso https://github.com/boot2docker/boot2docker/releases/download/v$BOOT2DOCKER_ISO_VERSION/boot2docker.iso
|
||||
# RUN curl -fsSL -o docker.exe "https://get.docker.com/builds/Windows/x86_64/docker-$DOCKER_VERSION.exe"
|
||||
RUN curl -fsSL -o docker.exe "https://test.docker.com/builds/Windows/x86_64/docker-$DOCKER_VERSION.exe"
|
||||
|
||||
RUN curl -fsSL -o docker-machine.zip "https://github.com/docker/machine/releases/download/v$DOCKER_MACHINE_VERSION/docker-machine_windows-amd64.zip" && \
|
||||
unzip docker-machine.zip && \
|
||||
rm docker-machine.zip
|
||||
|
||||
# RUN curl -fsSL -o boot2docker.iso https://github.com/boot2docker/boot2docker/releases/download/v$BOOT2DOCKER_ISO_VERSION/boot2docker.iso
|
||||
RUN curl -fsSL -o boot2docker.iso https://github.com/tianon/boot2docker-legacy/releases/download/v$BOOT2DOCKER_ISO_VERSION/boot2docker.iso
|
||||
|
||||
RUN curl -fsSL -o kitematic.zip "https://github.com/kitematic/kitematic/releases/download/v$KITEMATIC_VERSION/Kitematic-$KITEMATIC_VERSION-Windows-Alpha.zip" && \
|
||||
mkdir kitematic && \
|
||||
cd kitematic && \
|
||||
|
||||
3
Makefile
3
Makefile
@@ -6,6 +6,9 @@ DOCKER_WINDOWS_CONTAINER := build-windows-installer
|
||||
default: osx windows
|
||||
@true
|
||||
|
||||
clean: clean-osx clean-windows
|
||||
@true
|
||||
|
||||
osx: clean-osx
|
||||
docker build -t $(DOCKER_OSX_IMAGE) -f Dockerfile.osx .
|
||||
docker run --name "$(DOCKER_OSX_CONTAINER)" "$(DOCKER_OSX_IMAGE)"
|
||||
|
||||
@@ -53,7 +53,6 @@
|
||||
1B4C91C31B85198100A06068 /* InstallerSections.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = InstallerSections.plist; sourceTree = "<group>"; };
|
||||
1B8417E71B85261F00B1FA4D /* kitematic.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = kitematic.png; sourceTree = "<group>"; };
|
||||
1B8417E81B85261F00B1FA4D /* quickstart.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = quickstart.png; sourceTree = "<group>"; };
|
||||
1BB3EBCE1BA8C36000C2A3CF /* informationplugin.bundle */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; name = informationplugin.bundle; path = /Users/jmorgan/workspace/toolbox/osx/installerplugins/build/Debug/informationplugin.bundle; sourceTree = "<absolute>"; };
|
||||
1BF102BB1B8BDEDA00FCB650 /* overviewplugin.bundle */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = overviewplugin.bundle; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
1BF102BE1B8BDEDA00FCB650 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
|
||||
1BF102C01B8BDEDA00FCB650 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
|
||||
@@ -80,13 +79,6 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
1BF1029B1B8B940500FCB650 /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
1BF102B81B8BDEDA00FCB650 /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
@@ -227,23 +219,6 @@
|
||||
productReference = 1B4C91B31B85198100A06068 /* quickstartplugin.bundle */;
|
||||
productType = "com.apple.product-type.bundle";
|
||||
};
|
||||
1BF1029D1B8B940500FCB650 /* informationplugin */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = 1BF102B21B8B940500FCB650 /* Build configuration list for PBXNativeTarget "informationplugin" */;
|
||||
buildPhases = (
|
||||
1BF1029A1B8B940500FCB650 /* Sources */,
|
||||
1BF1029B1B8B940500FCB650 /* Frameworks */,
|
||||
1BF1029C1B8B940500FCB650 /* Resources */,
|
||||
);
|
||||
buildRules = (
|
||||
);
|
||||
dependencies = (
|
||||
);
|
||||
name = informationplugin;
|
||||
productName = informationplugin;
|
||||
productReference = 1BB3EBCE1BA8C36000C2A3CF /* informationplugin.bundle */;
|
||||
productType = "com.apple.product-type.bundle";
|
||||
};
|
||||
1BF102BA1B8BDEDA00FCB650 /* overviewplugin */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = 1BF102CD1B8BDEDA00FCB650 /* Build configuration list for PBXNativeTarget "overviewplugin" */;
|
||||
@@ -267,7 +242,7 @@
|
||||
1B4C906A1B84FDEB00A06068 /* Project object */ = {
|
||||
isa = PBXProject;
|
||||
attributes = {
|
||||
LastUpgradeCheck = 0640;
|
||||
LastUpgradeCheck = 0700;
|
||||
ORGANIZATIONNAME = "Docker Inc";
|
||||
TargetAttributes = {
|
||||
1B4C91411B8500A700A06068 = {
|
||||
@@ -276,9 +251,6 @@
|
||||
1B4C91B21B85198100A06068 = {
|
||||
CreatedOnToolsVersion = 6.4;
|
||||
};
|
||||
1BF1029D1B8B940500FCB650 = {
|
||||
CreatedOnToolsVersion = 6.4;
|
||||
};
|
||||
1BF102BA1B8BDEDA00FCB650 = {
|
||||
CreatedOnToolsVersion = 6.4;
|
||||
};
|
||||
@@ -299,7 +271,6 @@
|
||||
targets = (
|
||||
1B4C91411B8500A700A06068 /* managevmplugin */,
|
||||
1B4C91B21B85198100A06068 /* quickstartplugin */,
|
||||
1BF1029D1B8B940500FCB650 /* informationplugin */,
|
||||
1BF102BA1B8BDEDA00FCB650 /* overviewplugin */,
|
||||
);
|
||||
};
|
||||
@@ -333,13 +304,6 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
1BF1029C1B8B940500FCB650 /* Resources */ = {
|
||||
isa = PBXResourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
1BF102B91B8BDEDA00FCB650 /* Resources */ = {
|
||||
isa = PBXResourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
@@ -371,13 +335,6 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
1BF1029A1B8B940500FCB650 /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
1BF102B71B8BDEDA00FCB650 /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
@@ -484,6 +441,7 @@
|
||||
COPY_PHASE_STRIP = NO;
|
||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||
ENABLE_TESTABILITY = YES;
|
||||
GCC_C_LANGUAGE_STANDARD = gnu99;
|
||||
GCC_DYNAMIC_NO_PIC = NO;
|
||||
GCC_NO_COMMON_BLOCKS = YES;
|
||||
@@ -546,12 +504,14 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
COMBINE_HIDPI_IMAGES = YES;
|
||||
FRAMEWORK_SEARCH_PATHS = "$(inherited)";
|
||||
GCC_PREPROCESSOR_DEFINITIONS = (
|
||||
"DEBUG=1",
|
||||
"$(inherited)",
|
||||
);
|
||||
INFOPLIST_FILE = managevmplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "com.docker.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
@@ -561,8 +521,10 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
COMBINE_HIDPI_IMAGES = YES;
|
||||
FRAMEWORK_SEARCH_PATHS = "$(inherited)";
|
||||
INFOPLIST_FILE = managevmplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "com.docker.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
@@ -579,6 +541,7 @@
|
||||
INFOPLIST_FILE = quickstartplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "com.docker.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
@@ -592,35 +555,7 @@
|
||||
INFOPLIST_FILE = quickstartplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
1BF102B01B8B940500FCB650 /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
COMBINE_HIDPI_IMAGES = YES;
|
||||
GCC_PREPROCESSOR_DEFINITIONS = (
|
||||
"DEBUG=1",
|
||||
"$(inherited)",
|
||||
);
|
||||
INFOPLIST_FILE = informationplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
1BF102B11B8B940500FCB650 /* Release */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
COMBINE_HIDPI_IMAGES = YES;
|
||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||
INFOPLIST_FILE = informationplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "com.docker.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
@@ -637,6 +572,7 @@
|
||||
INFOPLIST_FILE = overviewplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "com.docker.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
@@ -650,6 +586,7 @@
|
||||
INFOPLIST_FILE = overviewplugin/Info.plist;
|
||||
INSTALL_PATH = "$(HOME)/Library/Bundles";
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "com.docker.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
WRAPPER_EXTENSION = bundle;
|
||||
};
|
||||
@@ -685,15 +622,6 @@
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
1BF102B21B8B940500FCB650 /* Build configuration list for PBXNativeTarget "informationplugin" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
1BF102B01B8B940500FCB650 /* Debug */,
|
||||
1BF102B11B8B940500FCB650 /* Release */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
1BF102CD1B8BDEDA00FCB650 /* Build configuration list for PBXNativeTarget "overviewplugin" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="7706" systemVersion="15A279b" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="8191" systemVersion="15B38b" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
|
||||
<dependencies>
|
||||
<deployment identifier="macosx"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="7706"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="8191"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<customObject id="-2" userLabel="File's Owner" customClass="InstallerSection">
|
||||
@@ -14,18 +14,16 @@
|
||||
<customObject id="-3" userLabel="Application" customClass="NSObject"/>
|
||||
<customObject id="Qsn-FY-4qK" customClass="managevmpluginPane">
|
||||
<connections>
|
||||
<outlet property="arrowImage" destination="dMU-aX-9b9" id="ASN-Jn-gwO"/>
|
||||
<outlet property="boot2dockerImage" destination="dPT-t6-boJ" id="l7a-8P-CZa"/>
|
||||
<outlet property="contentView" destination="wZl-Zt-3Ul" id="pOK-JC-MAY"/>
|
||||
<outlet property="issueButton" destination="a96-1q-EBq" id="xHH-VV-7rh"/>
|
||||
<outlet property="migrateCheckbox" destination="1jI-qj-TPj" id="Jez-nP-voL"/>
|
||||
<outlet property="migrateExtraLabel" destination="KQO-mX-hcI" id="Rg7-4S-ty5"/>
|
||||
<outlet property="migrationLogsScrollView" destination="UwA-bh-SQw" id="Zw0-AU-QPA"/>
|
||||
<outlet property="migrationLogsTextView" destination="ehz-gh-aXR" id="VW6-Zi-v52"/>
|
||||
<outlet property="migrationProgress" destination="uCY-2T-BB0" id="B4L-67-y5K"/>
|
||||
<outlet property="migrationStatusImage" destination="rc2-Ev-HMB" id="wbY-mD-33x"/>
|
||||
<outlet property="migrationStatusLabel" destination="PYI-QA-XWa" id="0I6-Jo-SZi"/>
|
||||
<outlet property="parentSection" destination="-2" id="FB7-UV-e8k"/>
|
||||
<outlet property="statusImage" destination="FO2-AK-Ue7" id="rYH-29-NhC"/>
|
||||
<outlet property="submitButton" destination="a96-1q-EBq" id="O1z-29-pYi"/>
|
||||
<outlet property="toolboxImage" destination="FO2-AK-Ue7" id="5iF-Bg-BdV"/>
|
||||
</connections>
|
||||
</customObject>
|
||||
@@ -33,16 +31,6 @@
|
||||
<rect key="frame" x="0.0" y="0.0" width="418" height="330"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView hidden="YES" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="dPT-t6-boJ">
|
||||
<rect key="frame" x="46" y="181" width="96" height="96"/>
|
||||
<animations/>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" id="fjp-1z-VlF"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="dMU-aX-9b9">
|
||||
<rect key="frame" x="190" y="210" width="38" height="38"/>
|
||||
<animations/>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyUpOrDown" image="NSFollowLinkFreestandingTemplate" id="7IH-3T-Kug"/>
|
||||
</imageView>
|
||||
<textField hidden="YES" horizontalHuggingPriority="251" verticalHuggingPriority="750" fixedFrame="YES" setsMaxLayoutWidthAtFirstLayout="YES" translatesAutoresizingMaskIntoConstraints="NO" id="KQO-mX-hcI">
|
||||
<rect key="frame" x="38" y="45" width="362" height="43"/>
|
||||
<animations/>
|
||||
@@ -60,15 +48,6 @@
|
||||
<font key="font" metaFont="system"/>
|
||||
</buttonCell>
|
||||
</button>
|
||||
<imageView hidden="YES" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="FO2-AK-Ue7">
|
||||
<rect key="frame" x="269" y="181" width="96" height="96"/>
|
||||
<animations/>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" id="KTv-gW-FBX"/>
|
||||
</imageView>
|
||||
<progressIndicator wantsLayer="YES" horizontalHuggingPriority="750" verticalHuggingPriority="750" fixedFrame="YES" maxValue="100" bezeled="NO" indeterminate="YES" style="spinning" translatesAutoresizingMaskIntoConstraints="NO" id="uCY-2T-BB0">
|
||||
<rect key="frame" x="193" y="213" width="32" height="32"/>
|
||||
<animations/>
|
||||
</progressIndicator>
|
||||
<textField hidden="YES" horizontalHuggingPriority="251" verticalHuggingPriority="750" fixedFrame="YES" setsMaxLayoutWidthAtFirstLayout="YES" translatesAutoresizingMaskIntoConstraints="NO" id="PYI-QA-XWa">
|
||||
<rect key="frame" x="18" y="166" width="382" height="28"/>
|
||||
<animations/>
|
||||
@@ -78,19 +57,14 @@
|
||||
<color key="backgroundColor" name="controlColor" catalog="System" colorSpace="catalog"/>
|
||||
</textFieldCell>
|
||||
</textField>
|
||||
<imageView hidden="YES" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="rc2-Ev-HMB">
|
||||
<rect key="frame" x="149" y="200" width="120" height="120"/>
|
||||
<animations/>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyUpOrDown" image="NSCaution" id="emX-FX-G94"/>
|
||||
</imageView>
|
||||
<scrollView hidden="YES" fixedFrame="YES" horizontalLineScroll="10" horizontalPageScroll="10" verticalLineScroll="10" verticalPageScroll="10" hasHorizontalScroller="NO" usesPredominantAxisScrolling="NO" translatesAutoresizingMaskIntoConstraints="NO" id="UwA-bh-SQw">
|
||||
<rect key="frame" x="0.0" y="-1" width="418" height="126"/>
|
||||
<clipView key="contentView" misplaced="YES" id="g1K-p4-gs1">
|
||||
<rect key="frame" x="1" y="1" width="223" height="133"/>
|
||||
<clipView key="contentView" ambiguous="YES" id="g1K-p4-gs1">
|
||||
<rect key="frame" x="1" y="1" width="416" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<textView editable="NO" importsGraphics="NO" richText="NO" findStyle="panel" continuousSpellChecking="YES" usesRuler="YES" usesFontPanel="YES" verticallyResizable="YES" allowsNonContiguousLayout="YES" quoteSubstitution="YES" dashSubstitution="YES" spellingCorrection="YES" smartInsertDelete="YES" id="ehz-gh-aXR">
|
||||
<rect key="frame" x="0.0" y="0.0" width="223" height="133"/>
|
||||
<textView ambiguous="YES" editable="NO" importsGraphics="NO" richText="NO" findStyle="panel" continuousSpellChecking="YES" usesRuler="YES" usesFontPanel="YES" verticallyResizable="YES" allowsNonContiguousLayout="YES" quoteSubstitution="YES" dashSubstitution="YES" spellingCorrection="YES" smartInsertDelete="YES" id="ehz-gh-aXR">
|
||||
<rect key="frame" x="0.0" y="0.0" width="416" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<animations/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
|
||||
@@ -110,8 +84,8 @@
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<animations/>
|
||||
</scroller>
|
||||
<scroller key="verticalScroller" verticalHuggingPriority="750" doubleValue="1" horizontal="NO" id="Pv6-xu-8lS">
|
||||
<rect key="frame" x="224" y="1" width="15" height="133"/>
|
||||
<scroller key="verticalScroller" verticalHuggingPriority="750" horizontal="NO" id="Pv6-xu-8lS">
|
||||
<rect key="frame" x="401" y="1" width="16" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<animations/>
|
||||
</scroller>
|
||||
@@ -119,20 +93,25 @@
|
||||
<button hidden="YES" verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="a96-1q-EBq">
|
||||
<rect key="frame" x="124" y="126" width="170" height="32"/>
|
||||
<animations/>
|
||||
<buttonCell key="cell" type="push" title="Submit GitHub Issue" bezelStyle="rounded" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="bna-Yz-WXL">
|
||||
<buttonCell key="cell" type="push" title="Open GitHub Issue" bezelStyle="rounded" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="bna-Yz-WXL">
|
||||
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
||||
<font key="font" metaFont="system"/>
|
||||
</buttonCell>
|
||||
<connections>
|
||||
<action selector="issueButtonClicked:" target="Qsn-FY-4qK" id="N6K-SY-Nde"/>
|
||||
<action selector="submitButtonClicked:" target="Qsn-FY-4qK" id="b4l-JE-Ssw"/>
|
||||
</connections>
|
||||
</button>
|
||||
<imageView hidden="YES" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="FO2-AK-Ue7">
|
||||
<rect key="frame" x="161" y="202" width="96" height="96"/>
|
||||
<animations/>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" id="KTv-gW-FBX"/>
|
||||
</imageView>
|
||||
<progressIndicator wantsLayer="YES" horizontalHuggingPriority="750" verticalHuggingPriority="750" fixedFrame="YES" maxValue="100" bezeled="NO" indeterminate="YES" style="spinning" translatesAutoresizingMaskIntoConstraints="NO" id="uCY-2T-BB0">
|
||||
<rect key="frame" x="193" y="133" width="32" height="32"/>
|
||||
<animations/>
|
||||
</progressIndicator>
|
||||
</subviews>
|
||||
<animations/>
|
||||
</customView>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="NSCaution" width="32" height="32"/>
|
||||
<image name="NSFollowLinkFreestandingTemplate" width="14" height="14"/>
|
||||
</resources>
|
||||
</document>
|
||||
|
||||
@@ -2,16 +2,12 @@
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>Mixpanel Token</key>
|
||||
<string>%MIXPANEL_TOKEN%</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>com.docker.$(PRODUCT_NAME:rfc1034identifier)</string>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
@@ -24,8 +20,12 @@
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>InstallerSectionTitle</key>
|
||||
<string>VM Migration</string>
|
||||
<key>Mixpanel Token</key>
|
||||
<string>%MIXPANEL_TOKEN%</string>
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>Copyright © 2015 Docker Inc. All rights reserved.</string>
|
||||
<key>NSMainNibFile</key>
|
||||
|
||||
@@ -10,18 +10,15 @@
|
||||
|
||||
@interface managevmpluginPane : InstallerPane
|
||||
|
||||
@property (weak) IBOutlet NSImageView *boot2dockerImage;
|
||||
@property (weak) IBOutlet NSImageView *toolboxImage;
|
||||
@property (weak) IBOutlet NSImageView *statusImage;
|
||||
@property (weak) IBOutlet NSButton *migrateCheckbox;
|
||||
@property (weak) IBOutlet NSTextField *migrateExtraLabel;
|
||||
@property (weak) IBOutlet NSProgressIndicator *migrationProgress;
|
||||
@property (weak) IBOutlet NSImageView *arrowImage;
|
||||
@property (weak) IBOutlet NSImageView *migrationStatusImage;
|
||||
@property (weak) IBOutlet NSTextField *migrationStatusLabel;
|
||||
@property (unsafe_unretained) IBOutlet NSTextView *migrationLogsTextView;
|
||||
@property (weak) IBOutlet NSScrollView *migrationLogsScrollView;
|
||||
@property (weak) IBOutlet NSButton *issueButton;
|
||||
@property (weak) IBOutlet NSButton *submitButton;
|
||||
|
||||
- (IBAction)issueButtonClicked:(id)sender;
|
||||
- (IBAction)submitButtonClicked:(id)sender;
|
||||
|
||||
@end
|
||||
|
||||
@@ -10,8 +10,9 @@
|
||||
#import "mixpanel.h"
|
||||
|
||||
@interface managevmpluginPane()
|
||||
@property BOOL migrating;
|
||||
@property BOOL successfullyMigrated;
|
||||
@property BOOL upgrading;
|
||||
@property BOOL locked;
|
||||
@property BOOL successful;
|
||||
@end
|
||||
|
||||
@implementation managevmpluginPane
|
||||
@@ -25,6 +26,35 @@ NSString *dockerMachinePath = @"/usr/local/bin/docker-machine";
|
||||
return [task terminationStatus] != 1;
|
||||
}
|
||||
|
||||
- (NSString *) boot2dockerISOVersionAtPath:(NSString*)path {
|
||||
NSTask* task = [[NSTask alloc] init];
|
||||
task.arguments = [NSArray arrayWithObjects:path, nil];
|
||||
task.launchPath = @"/usr/bin/file";
|
||||
|
||||
NSPipe * out = [NSPipe pipe];
|
||||
[task setStandardOutput:out];
|
||||
[task launch];
|
||||
[task waitUntilExit];
|
||||
|
||||
if (task.terminationStatus != 0) {
|
||||
return nil;
|
||||
}
|
||||
|
||||
NSFileHandle * read = [out fileHandleForReading];
|
||||
NSData * dataRead = [read readDataToEndOfFile];
|
||||
NSString * stringRead = [[NSString alloc] initWithData:dataRead encoding:NSUTF8StringEncoding];
|
||||
|
||||
NSCharacterSet *delimiters = [NSCharacterSet characterSetWithCharactersInString:@"v'"];
|
||||
NSArray *splitString = [stringRead componentsSeparatedByCharactersInSet:delimiters];
|
||||
|
||||
if (splitString.count < 3) {
|
||||
return nil;
|
||||
}
|
||||
|
||||
NSString *version = [[splitString objectAtIndex:2] stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]];
|
||||
return version;
|
||||
}
|
||||
|
||||
- (BOOL) canMigrateBoot2DockerVM {
|
||||
// VirtualBox and Docker Machine exist
|
||||
if (![[NSFileManager defaultManager] fileExistsAtPath:vBoxManagePath] || ![[NSFileManager defaultManager] fileExistsAtPath:dockerMachinePath]) {
|
||||
@@ -50,11 +80,32 @@ NSString *dockerMachinePath = @"/usr/local/bin/docker-machine";
|
||||
return YES;
|
||||
}
|
||||
|
||||
- (BOOL) canUpgradeBoot2DockerVM {
|
||||
// VirtualBox and Docker Machine exist
|
||||
if (![[NSFileManager defaultManager] fileExistsAtPath:vBoxManagePath] || ![[NSFileManager defaultManager] fileExistsAtPath:dockerMachinePath]) {
|
||||
return NO;
|
||||
}
|
||||
|
||||
// docker-machine path and VirtualBox VM exist
|
||||
if (![self vmExists:@"default"] ||
|
||||
![[NSFileManager defaultManager] fileExistsAtPath:[NSString stringWithFormat:@"%@/.docker/machine/machines/default", NSHomeDirectory()]] ||
|
||||
![[NSFileManager defaultManager] fileExistsAtPath:[NSString stringWithFormat:@"%@/.docker/machine/machines/default/boot2docker.iso", NSHomeDirectory()]]) {
|
||||
return NO;
|
||||
}
|
||||
|
||||
NSString *incomingVersion = [self boot2dockerISOVersionAtPath:[NSString stringWithFormat:@"%@/.docker/machine/cache/boot2docker.iso", NSHomeDirectory()]];
|
||||
NSString *existingVersion = [self boot2dockerISOVersionAtPath:[NSString stringWithFormat:@"%@/.docker/machine/machines/default/boot2docker.iso", NSHomeDirectory()]];
|
||||
|
||||
NSLog(@"%@", incomingVersion);
|
||||
NSLog(@"%@", existingVersion);
|
||||
|
||||
return [incomingVersion compare:existingVersion options:NSNumericSearch] != NSOrderedAscending;
|
||||
}
|
||||
|
||||
- (void) migrateBoot2DockerVM {
|
||||
self.locked = YES;
|
||||
|
||||
self.migrating = YES;
|
||||
|
||||
// Remove existing vm if it exists (obviously user must have deleted the
|
||||
// Remove existing vm if it exists
|
||||
NSTask* removeVMTask = [NSTask launchedTaskWithLaunchPath:@"/usr/bin/sudo" arguments:[NSArray arrayWithObjects:@"-i", @"-u", NSUserName(), dockerMachinePath, @"rm", @"-f", @"default", nil]];
|
||||
[removeVMTask waitUntilExit];
|
||||
|
||||
@@ -67,6 +118,68 @@ NSString *dockerMachinePath = @"/usr/local/bin/docker-machine";
|
||||
migrateTask.launchPath = @"/usr/bin/sudo";
|
||||
migrateTask.arguments = [NSArray arrayWithObjects:@"-i", @"-u", NSUserName(), dockerMachinePath, @"-D", @"create", @"-d", @"virtualbox", @"--virtualbox-memory", @"2048", @"--virtualbox-import-boot2docker-vm", @"boot2docker-vm", @"default", nil];
|
||||
|
||||
|
||||
[self runTask:migrateTask onFinish:^void (int status) {
|
||||
self.nextEnabled = YES;
|
||||
self.statusImage.hidden = YES;
|
||||
[self.migrationProgress stopAnimation:self];
|
||||
self.migrationProgress.hidden = YES;
|
||||
|
||||
self.migrationStatusLabel.hidden = NO;
|
||||
self.statusImage.hidden = NO;
|
||||
|
||||
if (status == 0) {
|
||||
self.successful = YES;
|
||||
self.migrationStatusLabel.stringValue = @"Your Boot2Docker VM was successfully migrated to a Docker Machine VM named \"default\".";
|
||||
self.statusImage.image = [[NSImage alloc]initWithContentsOfFile:[[NSBundle bundleForClass:[self class]] pathForResource:@"toolboxcheck" ofType:@"png"]];
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Succeeded" forPane:self];
|
||||
[self gotoNextPane];
|
||||
} else {
|
||||
self.migrationLogsScrollView.hidden = NO;
|
||||
self.submitButton.hidden = NO;
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Failed" forPane:self];
|
||||
self.migrationStatusLabel.hidden = NO;
|
||||
self.migrationStatusLabel.stringValue = @"Creating the VM failed. Following the install, try creating a vm manually via docker-machine.";
|
||||
}
|
||||
|
||||
}];
|
||||
}
|
||||
|
||||
- (void) upgradeBoot2DockerVM {
|
||||
self.locked = YES;
|
||||
|
||||
// Do the migration
|
||||
NSTask* task = [[NSTask alloc] init];
|
||||
task.launchPath = @"/usr/bin/sudo";
|
||||
task.arguments = [NSArray arrayWithObjects:@"-i", @"-u", NSUserName(), [NSString stringWithFormat:@"%@ stop default && cp %@/.docker/machine/cache/boot2docker.iso %@/.docker/machine/machines/default/boot2docker.iso", dockerMachinePath, NSHomeDirectory(), NSHomeDirectory()], nil];
|
||||
|
||||
[self runTask:task onFinish:^void (int status) {
|
||||
self.nextEnabled = YES;
|
||||
self.statusImage.hidden = YES;
|
||||
[self.migrationProgress stopAnimation:self];
|
||||
self.migrationProgress.hidden = YES;
|
||||
|
||||
self.migrationStatusLabel.hidden = NO;
|
||||
self.statusImage.hidden = NO;
|
||||
|
||||
if (status == 0) {
|
||||
self.successful = YES;
|
||||
self.migrationStatusLabel.stringValue = @"Your VirtualBox Docker VM named \"default\" was successfully upgraded.";
|
||||
self.statusImage.image = [[NSImage alloc]initWithContentsOfFile:[[NSBundle bundleForClass:[self class]] pathForResource:@"toolboxcheck" ofType:@"png"]];
|
||||
[Mixpanel trackEvent:@"VM Upgrade Succeeded" forPane:self];
|
||||
[self gotoNextPane];
|
||||
} else {
|
||||
self.migrationLogsScrollView.hidden = NO;
|
||||
self.submitButton.hidden = NO;
|
||||
[Mixpanel trackEvent:@"VM Upgrade Failed" forPane:self];
|
||||
self.migrationStatusLabel.hidden = NO;
|
||||
self.migrationStatusLabel.stringValue = @"Upgrading your VirtualBox Docker VM Failed. Try upgrading again manually via the docker-machine command.";
|
||||
}
|
||||
|
||||
}];
|
||||
}
|
||||
|
||||
- (void) runTask:(NSTask *)task onFinish:(void (^)(int))finish {
|
||||
// Remove certificates, ssh keys from logs
|
||||
NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"BEGIN.*END" options:NSRegularExpressionDotMatchesLineSeparators error:NULL];
|
||||
NSFont *font = [NSFont fontWithName:@"Menlo" size:10.0];
|
||||
@@ -84,48 +197,26 @@ NSString *dockerMachinePath = @"/usr/local/bin/docker-machine";
|
||||
[self.migrationLogsTextView scrollRangeToVisible:NSMakeRange([[self.migrationLogsTextView string] length], 0)];
|
||||
});
|
||||
};
|
||||
|
||||
migrateTask.standardOutput = [NSPipe pipe];
|
||||
migrateTask.standardError = [NSPipe pipe];
|
||||
|
||||
[[migrateTask.standardOutput fileHandleForReading] setReadabilityHandler:appendOutput];
|
||||
[[migrateTask.standardError fileHandleForReading] setReadabilityHandler:appendOutput];
|
||||
task.standardOutput = [NSPipe pipe];
|
||||
task.standardError = [NSPipe pipe];
|
||||
|
||||
migrateTask.terminationHandler = ^(NSTask* task) {
|
||||
[[task.standardOutput fileHandleForReading] setReadabilityHandler:appendOutput];
|
||||
[[task.standardError fileHandleForReading] setReadabilityHandler:appendOutput];
|
||||
|
||||
task.terminationHandler = ^(NSTask* task) {
|
||||
dispatch_async(dispatch_get_main_queue(), ^{
|
||||
[task.standardOutput fileHandleForReading].readabilityHandler = nil;
|
||||
|
||||
self.boot2dockerImage.hidden = YES;
|
||||
self.toolboxImage.hidden = YES;
|
||||
[self.migrationProgress stopAnimation:self];
|
||||
self.migrationProgress.hidden = YES;
|
||||
|
||||
self.migrationStatusLabel.hidden = NO;
|
||||
self.migrationStatusImage.hidden = NO;
|
||||
|
||||
if (task.terminationStatus == 0) {
|
||||
self.successfullyMigrated = YES;
|
||||
self.migrationStatusLabel.stringValue = @"Your Boot2Docker VM was successfully migrated to a Docker Machine VM named \"default\".";
|
||||
self.migrationStatusImage.image = [[NSImage alloc]initWithContentsOfFile:[[NSBundle bundleForClass:[self class]] pathForResource:@"toolboxcheck" ofType:@"png"]];
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Succeeded" forPane:self];
|
||||
self.nextEnabled = YES;
|
||||
[self gotoNextPane];
|
||||
} else {
|
||||
self.migrationLogsScrollView.hidden = NO;
|
||||
self.issueButton.hidden = NO;
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Failed" forPane:self];
|
||||
self.migrationStatusLabel.hidden = NO;
|
||||
self.migrationStatusLabel.stringValue = @"VM Migration failed. Please see the logs below.";
|
||||
}
|
||||
finish(task.terminationStatus);
|
||||
});
|
||||
};
|
||||
|
||||
[migrateTask launch];
|
||||
[task launch];
|
||||
}
|
||||
|
||||
- (id) init {
|
||||
self.migrating = NO;
|
||||
self.successfullyMigrated = NO;
|
||||
self.upgrading = NO;
|
||||
self.successful = NO;
|
||||
self = [super init];
|
||||
return self;
|
||||
}
|
||||
@@ -136,34 +227,30 @@ NSString *dockerMachinePath = @"/usr/local/bin/docker-machine";
|
||||
|
||||
- (void) didEnterPane:(InstallerSectionDirection)dir {
|
||||
[Mixpanel trackEvent:@"Installing Files Succeeded" forPane:self];
|
||||
if (self.successfullyMigrated) {
|
||||
self.nextEnabled = YES;
|
||||
return;
|
||||
}
|
||||
|
||||
if (self.migrating) {
|
||||
self.nextEnabled = NO;
|
||||
return;
|
||||
}
|
||||
self.previousEnabled = NO;
|
||||
|
||||
NSImage *toolboxImage = [[NSImage alloc]initWithContentsOfFile:[[NSBundle bundleForClass:[self class]] pathForResource:@"toolbox" ofType:@"png"]];
|
||||
NSImage *boot2dockerImage = [[NSImage alloc] initWithContentsOfFile:[[NSBundle bundleForClass:[self class]] pathForResource:@"boot2docker" ofType:@"png"]];
|
||||
|
||||
[self.migrationProgress startAnimation:self];
|
||||
|
||||
if ([self canMigrateBoot2DockerVM]) {
|
||||
NSImage *image = [[NSImage alloc] initWithContentsOfFile:[[NSBundle bundleForClass:[self class]] pathForResource:@"boot2docker" ofType:@"png"]];
|
||||
self.boot2dockerImage.image = image;
|
||||
self.boot2dockerImage.hidden = NO;
|
||||
NSImage *toolboxImage = [[NSImage alloc]initWithContentsOfFile:[[NSBundle bundleForClass:[self class]] pathForResource:@"toolbox" ofType:@"png"]];
|
||||
self.toolboxImage.image = toolboxImage;
|
||||
self.toolboxImage.hidden = NO;
|
||||
self.arrowImage.hidden = NO;
|
||||
self.migrateCheckbox.hidden = NO;
|
||||
self.migrateCheckbox.enabled = YES;
|
||||
self.migrateExtraLabel.hidden = NO;
|
||||
[self.migrationProgress stopAnimation:self];
|
||||
self.migrationProgress.hidden = YES;
|
||||
|
||||
if ([self canUpgradeBoot2DockerVM]) {
|
||||
self.migrateCheckbox.title = [NSString stringWithFormat:@"Upgrade your Docker Toolbox VM to Docker %@", [self boot2dockerISOVersionAtPath:[NSString stringWithFormat:@"%@/.docker/machine/cache/boot2docker.iso", NSHomeDirectory()]]] ;
|
||||
self.migrateExtraLabel.stringValue = @"Your existing Docker Toolbox VM will not be affected. This should take about a minute.";
|
||||
self.statusImage.image = toolboxImage;
|
||||
self.upgrading = YES;
|
||||
} else if ([self canMigrateBoot2DockerVM]) {
|
||||
self.statusImage.image = boot2dockerImage;
|
||||
} else {
|
||||
[self gotoNextPane];
|
||||
}
|
||||
|
||||
self.statusImage.hidden = NO;
|
||||
self.migrateCheckbox.hidden = NO;
|
||||
self.migrateCheckbox.enabled = YES;
|
||||
self.migrateExtraLabel.hidden = NO;
|
||||
self.migrationProgress.hidden = YES;
|
||||
[self.migrationProgress stopAnimation:self];
|
||||
}
|
||||
|
||||
- (BOOL) shouldExitPane:(InstallerSectionDirection)dir {
|
||||
@@ -172,27 +259,38 @@ NSString *dockerMachinePath = @"/usr/local/bin/docker-machine";
|
||||
}
|
||||
|
||||
if (self.migrateCheckbox.enabled && self.migrateCheckbox.state == NSOnState) {
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Started" forPane:self];
|
||||
|
||||
self.nextEnabled = false;
|
||||
self.migrationProgress.hidden = NO;
|
||||
[self.migrationProgress startAnimation:self];
|
||||
self.migrationStatusLabel.hidden = NO;
|
||||
self.arrowImage.hidden = YES;
|
||||
self.migrateCheckbox.enabled = NO;
|
||||
self.migrationStatusLabel.stringValue = @"Migrating...";
|
||||
[self.migrationProgress startAnimation:self];
|
||||
|
||||
if (self.upgrading) {
|
||||
[Mixpanel trackEvent:@"VM Upgrade Started" forPane:self];
|
||||
self.migrationStatusLabel.stringValue = @"Upgrading...";
|
||||
[self upgradeBoot2DockerVM];
|
||||
} else {
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Started" forPane:self];
|
||||
self.migrationStatusLabel.stringValue = @"Migrating...";
|
||||
[self migrateBoot2DockerVM];
|
||||
}
|
||||
|
||||
[self migrateBoot2DockerVM];
|
||||
return NO;
|
||||
} else if (self.migrateCheckbox.state == NSOffState) {
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Skipped" forPane:self];
|
||||
if (self.upgrading) {
|
||||
[Mixpanel trackEvent:@"VM Upgrade Skipped" forPane:self];
|
||||
} else {
|
||||
[Mixpanel trackEvent:@"Boot2Docker Migration Skipped" forPane:self];
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return YES;
|
||||
}
|
||||
|
||||
|
||||
- (IBAction)issueButtonClicked:(id)sender {
|
||||
- (IBAction)submitButtonClicked:(id)sender {
|
||||
NSURL *url = [[NSURL alloc] initWithString: @"https://github.com/docker/toolbox/issues"];
|
||||
[[NSWorkspace sharedWorkspace] openURL:url];
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>com.docker.$(PRODUCT_NAME:rfc1034identifier)</string>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
@@ -20,17 +20,17 @@
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>InstallerSectionTitle</key>
|
||||
<string>Overview</string>
|
||||
<key>Mixpanel Token</key>
|
||||
<string>%MIXPANEL_TOKEN%</string>
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>Copyright © 2015 Docker Inc. All rights reserved.</string>
|
||||
<key>NSMainNibFile</key>
|
||||
<string>overviewplugin</string>
|
||||
<key>NSPrincipalClass</key>
|
||||
<string>InstallerSection</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>Mixpanel Token</key>
|
||||
<string>%MIXPANEL_TOKEN%</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
@@ -41,18 +41,16 @@
|
||||
if (dir != InstallerDirectionForward) {
|
||||
return;
|
||||
}
|
||||
|
||||
[Mixpanel trackEvent:@"Continued from Overview" forPane:self];
|
||||
}
|
||||
|
||||
- (IBAction)checkboxChanged:(id)sender {
|
||||
if ([(NSButton*)sender state] == NSOnState) {
|
||||
[Mixpanel trackEvent:@"Enabled Tracking" forPane:self];
|
||||
[[[self section] sharedDictionary] removeObjectForKey:@"disableTracking"];
|
||||
} else {
|
||||
[Mixpanel trackEvent:@"Disabled Tracking" forPane:self];
|
||||
|
||||
BOOL enabled = self.checkbox.state == NSOnState;
|
||||
[Mixpanel trackEvent:@"Continued from Overview" forPane:self withProperties:[[NSDictionary alloc] initWithObjectsAndKeys:enabled ? @"Yes" : @"No", @"Tracking Enabled", nil]];
|
||||
|
||||
if (!enabled) {
|
||||
[[[self section] sharedDictionary] setObject:[NSNumber numberWithBool:YES] forKey:@"disableTracking"];
|
||||
} else {
|
||||
[[[self section] sharedDictionary] removeObjectForKey:@"disableTracking"];
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="7706" systemVersion="15A263e" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="8191" systemVersion="15B17c" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
|
||||
<dependencies>
|
||||
<deployment identifier="macosx"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="7706"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="8191"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<customObject id="-2" userLabel="File's Owner" customClass="InstallerSection">
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>com.docker.$(PRODUCT_NAME:rfc1034identifier)</string>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
@@ -20,17 +20,17 @@
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>InstallerSectionTitle</key>
|
||||
<string>quickstartplugin</string>
|
||||
<key>Mixpanel Token</key>
|
||||
<string>%MIXPANEL_TOKEN%</string>
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>Copyright © 2015 Docker Inc. All rights reserved.</string>
|
||||
<key>NSMainNibFile</key>
|
||||
<string>quickstartplugin</string>
|
||||
<key>NSPrincipalClass</key>
|
||||
<string>InstallerSection</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>Mixpanel Token</key>
|
||||
<string>%MIXPANEL_TOKEN%</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
<options customize="allow" allow-external-scripts="yes" rootVolumeOnly="true" hostArchitectures="x86_64"/>
|
||||
<background file="toolbox.png" alignment="bottomleft" scaling="none"/>
|
||||
<welcome file="welcome.rtfd" mime-type="text/rtfd"/>
|
||||
<conclusion file="Installed.html" mime-type="text/html"/>
|
||||
<choices-outline>
|
||||
<line choice="choiceDockerCLI"/>
|
||||
<line choice="choiceDockerMachineCLI"/>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>BuildMachineOSBuild</key>
|
||||
<string>15A282b</string>
|
||||
<string>15B38b</string>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
@@ -20,22 +20,26 @@
|
||||
<string>1.0</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleSupportedPlatforms</key>
|
||||
<array>
|
||||
<string>MacOSX</string>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<key>DTCompiler</key>
|
||||
<string>com.apple.compilers.llvm.clang.1_0</string>
|
||||
<key>DTPlatformBuild</key>
|
||||
<string>6E35b</string>
|
||||
<string>7A1001</string>
|
||||
<key>DTPlatformVersion</key>
|
||||
<string>GM</string>
|
||||
<key>DTSDKBuild</key>
|
||||
<string>14D125</string>
|
||||
<string>15A278</string>
|
||||
<key>DTSDKName</key>
|
||||
<string>macosx10.10</string>
|
||||
<string>macosx10.11</string>
|
||||
<key>DTXcode</key>
|
||||
<string>0640</string>
|
||||
<string>0701</string>
|
||||
<key>DTXcodeBuild</key>
|
||||
<string>6E35b</string>
|
||||
<string>7A1001</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>InstallerSectionTitle</key>
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -3,7 +3,7 @@
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>BuildMachineOSBuild</key>
|
||||
<string>15A279b</string>
|
||||
<string>15B38b</string>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
@@ -20,22 +20,26 @@
|
||||
<string>1.0</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleSupportedPlatforms</key>
|
||||
<array>
|
||||
<string>MacOSX</string>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<key>DTCompiler</key>
|
||||
<string>com.apple.compilers.llvm.clang.1_0</string>
|
||||
<key>DTPlatformBuild</key>
|
||||
<string>6E35b</string>
|
||||
<string>7A1001</string>
|
||||
<key>DTPlatformVersion</key>
|
||||
<string>GM</string>
|
||||
<key>DTSDKBuild</key>
|
||||
<string>14D125</string>
|
||||
<string>15A278</string>
|
||||
<key>DTSDKName</key>
|
||||
<string>macosx10.10</string>
|
||||
<string>macosx10.11</string>
|
||||
<key>DTXcode</key>
|
||||
<string>0640</string>
|
||||
<string>0701</string>
|
||||
<key>DTXcodeBuild</key>
|
||||
<string>6E35b</string>
|
||||
<string>7A1001</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>InstallerSectionTitle</key>
|
||||
|
||||
Binary file not shown.
@@ -3,7 +3,7 @@
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>BuildMachineOSBuild</key>
|
||||
<string>15A279b</string>
|
||||
<string>15B38b</string>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
@@ -20,22 +20,26 @@
|
||||
<string>1.0</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleSupportedPlatforms</key>
|
||||
<array>
|
||||
<string>MacOSX</string>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<key>DTCompiler</key>
|
||||
<string>com.apple.compilers.llvm.clang.1_0</string>
|
||||
<key>DTPlatformBuild</key>
|
||||
<string>6E35b</string>
|
||||
<string>7A1001</string>
|
||||
<key>DTPlatformVersion</key>
|
||||
<string>GM</string>
|
||||
<key>DTSDKBuild</key>
|
||||
<string>14D125</string>
|
||||
<string>15A278</string>
|
||||
<key>DTSDKName</key>
|
||||
<string>macosx10.10</string>
|
||||
<string>macosx10.11</string>
|
||||
<key>DTXcode</key>
|
||||
<string>0640</string>
|
||||
<string>0701</string>
|
||||
<key>DTXcodeBuild</key>
|
||||
<string>6E35b</string>
|
||||
<string>7A1001</string>
|
||||
<key>Installer Version</key>
|
||||
<string>%INSTALLER_VERSION%</string>
|
||||
<key>InstallerSectionTitle</key>
|
||||
|
||||
Binary file not shown.
@@ -4,7 +4,7 @@
|
||||
'choiceDockerCLI_msg' = 'Installs the Docker Client for Mac OS X into /usr/local/bin/';
|
||||
|
||||
'choiceDockerMachineCLI_title' = 'Docker Machine %DOCKERMACHINE_VERSION%';
|
||||
'choiceDockerMachineCLI_msg' = 'Installs the Docker Machine binary into /usr/local/bin/';
|
||||
'choiceDockerMachineCLI_msg' = 'Installs the Docker Machine binaries into /usr/local/bin/';
|
||||
|
||||
'choiceDockerComposeCLI_title' = 'Docker Compose %DOCKERCOMPOSE_VERSION%';
|
||||
'choiceDockerComposeCLI_msg' = 'Installs the Docker Compose binary into /usr/local/bin/';
|
||||
|
||||
@@ -10,5 +10,5 @@ chown -R $CONSOLE_USER:staff $CONSOLE_USER_HOME/.docker
|
||||
|
||||
# Fix permissions on binaries
|
||||
chown -R $CONSOLE_USER:admin /usr/local/bin/docker || true
|
||||
chown -R $CONSOLE_USER:admin /usr/local/bin/docker-machine || true
|
||||
chown -R $CONSOLE_USER:admin /usr/local/bin/docker-machine* || true
|
||||
chown -R $CONSOLE_USER:admin /usr/local/bin/docker-compose || true
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
#define b2dIsoPath "..\bundle\boot2docker.iso"
|
||||
#define dockerCli "..\bundle\docker.exe"
|
||||
#define dockerMachineCli "..\bundle\docker-machine.exe"
|
||||
#define dockerMachineCli "..\bundle\docker-machine*.exe"
|
||||
#define kitematic "..\bundle\kitematic"
|
||||
#define git "..\bundle\Git.exe"
|
||||
#define virtualBoxCommon "..\bundle\common.cab"
|
||||
@@ -28,7 +28,8 @@ DefaultDirName={pf}\{#MyAppName}
|
||||
DefaultGroupName=Docker
|
||||
DisableProgramGroupPage=yes
|
||||
OutputBaseFilename=DockerToolbox
|
||||
Compression=lzma
|
||||
// Compression=lzma
|
||||
Compression=none
|
||||
SolidCompression=yes
|
||||
WizardImageFile=windows-installer-side.bmp
|
||||
WizardSmallImageFile=windows-installer-logo.bmp
|
||||
@@ -51,6 +52,7 @@ Filename: "{win}\explorer.exe"; Parameters: "{userprograms}\Docker\"; Flags: pos
|
||||
[Tasks]
|
||||
Name: desktopicon; Description: "{cm:CreateDesktopIcon}"
|
||||
Name: modifypath; Description: "Add docker.exe & docker-machine.exe to &PATH"
|
||||
Name: upgradevm; Description: "Upgrade or Migrate Boot2Docker VM to latest version of Docker if it exists."
|
||||
|
||||
[Components]
|
||||
Name: "Docker"; Description: "Docker Client for Windows" ; Types: full custom; Flags: fixed
|
||||
@@ -166,6 +168,14 @@ begin
|
||||
);
|
||||
end;
|
||||
|
||||
function VBoxPath(): String;
|
||||
begin
|
||||
if GetEnv('VBOX_INSTALL_PATH') <> '' then
|
||||
Result := GetEnv('VBOX_INSTALL_PATH')
|
||||
else
|
||||
Result := GetEnv('VBOX_MSI_INSTALL_PATH')
|
||||
end;
|
||||
|
||||
function NeedToInstallGit(): Boolean;
|
||||
begin
|
||||
// TODO: Find a better way to see if Git is installed
|
||||
@@ -233,7 +243,7 @@ begin
|
||||
TrackingLabel.Height := 100;
|
||||
|
||||
// Don't do this until we can compare versions
|
||||
// Wizardform.ComponentsList.Checked[2] := NeedToInstallVirtualBox();
|
||||
Wizardform.ComponentsList.Checked[2] := NeedToInstallVirtualBox();
|
||||
Wizardform.ComponentsList.ItemEnabled[2] := not NeedToInstallVirtualBox();
|
||||
Wizardform.ComponentsList.Checked[4] := NeedToInstallGit();
|
||||
Wizardform.ComponentsList.ItemEnabled[4] := not NeedToInstallGit();
|
||||
@@ -287,26 +297,71 @@ begin
|
||||
MsgBox('File moving failed!', mbError, MB_OK);
|
||||
end;
|
||||
|
||||
function CanUpgradeVM(): Boolean;
|
||||
var
|
||||
ResultCode: Integer;
|
||||
begin
|
||||
if NeedToInstallVirtualBox() or not FileExists(ExpandConstant('{app}\docker-machine.exe')) then begin
|
||||
Result := false
|
||||
exit
|
||||
end;
|
||||
|
||||
ExecAsOriginalUser(VBoxPath() + 'VBoxManage.exe', 'showvminfo default', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
|
||||
if ResultCode <> 0 then begin
|
||||
Result := false
|
||||
exit
|
||||
end;
|
||||
|
||||
if not DirExists(ExpandConstant('{userdocs}\..\.docker\machine\machines\default')) then begin
|
||||
Result := false
|
||||
exit
|
||||
end;
|
||||
|
||||
Result := true
|
||||
end;
|
||||
|
||||
function UpgradeVM() : Boolean;
|
||||
var
|
||||
ResultCode: Integer;
|
||||
begin
|
||||
TrackEvent('VM Upgrade Started');
|
||||
WizardForm.StatusLabel.Caption := 'Upgrading Docker Toolbox VM...'
|
||||
ExecAsOriginalUser(ExpandConstant('{app}\docker-machine.exe'), 'stop default', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
|
||||
if ResultCode = 0 then
|
||||
begin
|
||||
FileCopy(ExpandConstant('{userdocs}\..\.docker\machine\cache\boot2docker.iso'), ExpandConstant('{userdocs}\..\.docker\machine\machines\default\boot2docker.iso'), false)
|
||||
TrackEvent('VM Upgrade Succeeded');
|
||||
end
|
||||
else begin
|
||||
TrackEvent('VM Upgrade Failed');
|
||||
MsgBox('VM Upgrade Failed because the VirtualBox VM could not be stopped.', mbCriticalError, MB_OK);
|
||||
Result := false
|
||||
WizardForm.Close;
|
||||
exit;
|
||||
end;
|
||||
Result := true
|
||||
end;
|
||||
|
||||
function MigrateVM() : Boolean;
|
||||
var
|
||||
ResultCode: Integer;
|
||||
begin
|
||||
if NeedToInstallGit() or NeedToInstallVirtualBox() or not FileExists(ExpandConstant('{app}\docker-machine.exe')) then begin
|
||||
Result := true
|
||||
exit
|
||||
end;
|
||||
if NeedToInstallGit() or NeedToInstallVirtualBox() 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)
|
||||
if ResultCode <> 1 then begin
|
||||
Result := true
|
||||
exit
|
||||
end;
|
||||
ExecAsOriginalUser(VBoxPath() + 'VBoxManage.exe', 'showvminfo default', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
|
||||
if ResultCode <> 1 then begin
|
||||
Result := true
|
||||
exit
|
||||
end;
|
||||
|
||||
ExecAsOriginalUser('C:\Program Files\Oracle\VirtualBox\VBoxManage.exe', 'showvminfo boot2docker-vm', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
|
||||
if ResultCode <> 0 then begin
|
||||
Result := true
|
||||
exit
|
||||
end;
|
||||
ExecAsOriginalUser(VBoxPath() + 'VBoxManage.exe', 'showvminfo boot2docker-vm', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
|
||||
if ResultCode <> 0 then begin
|
||||
Result := true
|
||||
exit
|
||||
end;
|
||||
|
||||
if MsgBox('Migrate your existing Boot2Docker VM to work with the Docker Toolbox? Your existing Boot2Docker VM will not be affected. This should take about a minute.', mbConfirmation, MB_YESNO) = IDYES then
|
||||
begin
|
||||
@@ -348,20 +403,6 @@ begin
|
||||
end;
|
||||
#include "modpath.iss"
|
||||
|
||||
procedure CurPageChanged(CurPageID: Integer);
|
||||
begin
|
||||
if (CurPageID = wpFinished) then
|
||||
begin
|
||||
WizardForm.FinishedLabel.AutoSize := True;
|
||||
WizardForm.FinishedLabel.Font.Style := [fsBold];
|
||||
WizardForm.FinishedLabel.Caption :=
|
||||
'Upgrade your default Docker VM using the command:' + \
|
||||
#13#10 + \
|
||||
#13#10 + \
|
||||
' `docker-machine upgrade default`';
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure CurStepChanged(CurStep: TSetupStep);
|
||||
var
|
||||
Success: Boolean;
|
||||
@@ -372,7 +413,18 @@ begin
|
||||
if IsTaskSelected(ModPathName) then
|
||||
ModPath();
|
||||
if not WizardSilent() then
|
||||
Success := MigrateVM();
|
||||
begin
|
||||
if IsTaskSelected('upgradevm') then
|
||||
begin
|
||||
if CanUpgradeVM() then begin
|
||||
Success := UpgradeVM();
|
||||
end
|
||||
else begin
|
||||
Success := MigrateVM();
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
if Success then
|
||||
trackEvent('Installer Finished');
|
||||
end;
|
||||
|
||||
Reference in New Issue
Block a user