1
0
mirror of https://github.com/rancher/os.git synced 2025-09-23 03:20:07 +00:00

Merge pull request #1859 from SvenDowideit/fix-dev-version-check

fix ros-install version check for dev builds
This commit is contained in:
Sven Dowideit
2017-05-17 22:24:03 +10:00
committed by GitHub
2 changed files with 20 additions and 17 deletions

View File

@@ -197,6 +197,7 @@ func runInstall(image, installType, cloudConfig, device, partition, statedir, ka
log.Infof("user specified to install pre v0.8.0: %s", image)
imageVersion = strings.Replace(imageVersion, "-", ".", -1)
vArray := strings.Split(imageVersion, ".")
if len(vArray) >= 2 {
v, _ := strconv.ParseFloat(vArray[0]+"."+vArray[1], 32)
if v < 0.8 || imageVersion == "0.8.0-rc1" {
log.Infof("starting installer container for %s", image)
@@ -220,6 +221,7 @@ func runInstall(image, installType, cloudConfig, device, partition, statedir, ka
return nil
}
}
}
if _, err := os.Stat("/usr/bin/system-docker"); os.IsNotExist(err) {
if err := os.Symlink("/usr/bin/ros", "/usr/bin/system-docker"); err != nil {

View File

@@ -159,7 +159,8 @@ fi
if [ "$BOOT_PXE" == "1" ]; then
set -ex
sudo pixiecore boot \
PIXIECORE=$(which pixiecore)
sudo -E $PIXIECORE boot \
"${KERNEL}" \
"${INITRD}" \
--cmdline="${KERNEL_ARGS}"