[mapguide-commits] r8949 - in branches/3.0/vagrant: . centos6/src_update centos6/x64 centos6/x86 packer packer/http scripts ubuntu12/x64 ubuntu12/x86 ubuntu14/x64 ubuntu14/x86
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Tue May 10 06:15:13 PDT 2016
Author: jng
Date: 2016-05-10 06:15:13 -0700 (Tue, 10 May 2016)
New Revision: 8949
Added:
branches/3.0/vagrant/build_target.bat
branches/3.0/vagrant/centos6/
branches/3.0/vagrant/packer/README.txt
branches/3.0/vagrant/packer/http/ubuntu-14.04.4/
branches/3.0/vagrant/packer/ubuntu14-amd64.json
branches/3.0/vagrant/packer/ubuntu14-i386.json
branches/3.0/vagrant/ubuntu12/
branches/3.0/vagrant/ubuntu14/
branches/3.0/vagrant/update_sources.bat
Removed:
branches/3.0/vagrant/build.bat
branches/3.0/vagrant/centos/
branches/3.0/vagrant/packer/http/ubuntu-14.04/
branches/3.0/vagrant/ubuntu/
Modified:
branches/3.0/vagrant/
branches/3.0/vagrant/README.txt
branches/3.0/vagrant/centos6/src_update/Vagrantfile
branches/3.0/vagrant/centos6/x64/Vagrantfile
branches/3.0/vagrant/centos6/x86/Vagrantfile
branches/3.0/vagrant/make_boxes.bat
branches/3.0/vagrant/scripts/provision_centos.sh
branches/3.0/vagrant/scripts/provision_ubuntu.sh
branches/3.0/vagrant/ubuntu12/x64/Vagrantfile
branches/3.0/vagrant/ubuntu12/x86/Vagrantfile
branches/3.0/vagrant/ubuntu14/x64/Vagrantfile
branches/3.0/vagrant/ubuntu14/x86/Vagrantfile
Log:
Merged revision(s) 8947 from trunk/Tools/Vagrant:
Add README.txt for packer templates
........
Merged revision(s) 8933-8946 from trunk/Tools/Vagrant:
Remove liboss4-salsa-dev from ubuntu pre-requisites. We only installed this library only for the atomic.h that is packaged with this library, which our vagrant build system already copies into the expected location if it doesn't already exist.
........
vagrant: Increase CoordinateSystem unit test timeout
........
#2590: Add packer box templates for Ubuntu 14.04
........
Vagrant build environment updates:
- Add new build_target.bat that is basically the build.bat split up so that it can be used against any vagrant VM target.
- provision_ubuntu.sh:
- Don't copy MapGuide .tar.xz files to build output (because MapGuide tarballs are not created on Ubuntu)
- sudo run ./dpkgmapguide.sh
........
#2590: Add Ubuuntu 14 vagrantfiles
........
Rename our existing vagrant configurations
- centos -> centos6
- ubuntu -> ubuntu12
........
Rename build.bat to update_sources.bat. This file now only contains the source tarball updating part of the original file, as the build VM provisioning logic has been moved to build_target.bat, which now also has the nice side-effect of being able to run multiple build_target.bat instances in parallel for different distro/target configurations given sufficient computing grunt to pull it off, whereas the old build.bat had to do this sequentially.
Also update README.txt to reflect these changes.
........
Property changes on: branches/3.0/vagrant
___________________________________________________________________
Modified: svn:mergeinfo
- /trunk/Tools/Vagrant:8932
+ /trunk/Tools/Vagrant:8932-8947
Modified: branches/3.0/vagrant/README.txt
===================================================================
--- branches/3.0/vagrant/README.txt 2016-05-10 12:47:30 UTC (rev 8948)
+++ branches/3.0/vagrant/README.txt 2016-05-10 13:15:13 UTC (rev 8949)
@@ -23,6 +23,8 @@
* CentOS 6.5 64-bit
* Ubuntu 12.04 32-bit
* Ubuntu 12.04 64-bit
+ * Ubuntu 14.04 32-bit
+ * Ubuntu 14.04 64-bit
These boxes will also be registered in vagrant as:
@@ -30,37 +32,68 @@
* centos6-amd64
* ubuntu12-i386
* ubuntu12-amd64
+ * ubuntu14-i386
+ * ubuntu14-amd64
+Which you can confirm by running 'vagrant box list' from the command line
+
Building MapGuide and FDO
=========================
-Run build.bat, this will build MapGuide and FDO for:
+Building MapGuide and FDO requires you have source tarballs for MapGuide/FDO under the sources directory. See sources\README.txt for
+more information about the expected layout and naming conventions of the tarballs.
- * CentOS 6.5 32-bit
- * CentOS 6.5 64-bit
- * Ubuntu 12.04 32-bit
- * Ubuntu 12.04 64-bit
+Run build_target.bat with the following parameters:
-If MG_SVN_UPDATE_SOURCES is set to 1 before running build.bat, a special CentOS VM will be spun up to svn update the MapGuide and FDO source
-tarballs to the latest revisions. Otherwise, the existing source tarballs will be built at their last updated svn revision.
+ * -distro
+ * Build MapGuide/FDO for the given distro
+ * Valid values include:
+ * centos6
+ * ubuntu12
+ * ubuntu14
+ * -target
+ * Build MapGuide/FDO for the given distro using the given CPU configuration
+ * Valid values include:
+ * x86
+ * x64
+ * -ext
+ * The file extension of the build artifacts to collect from the vagrant VM's build output directory
+ * Valid values include"
+ * deb (for Ubuntu-based builds)
+ * tar.xz (for non-Ubuntu builds)
+ * -teardown
+ * Indicates whether to automatically tear down the VM once the build has completed.
+ * Set to 1 or 0
+For the rest of this section:
+ * $distro refers to the parameter you supplied for -distro
+ * $target refers to the parameter you supplied for -target
+
+This will build MapGuide/FDO with the existing source tarballs at their last updated svn revision. It will spin up a build VM
+using the vagrantfile located under the $distro\$target directory.
+
+If you have the computing grunt, you can run multiple build_target.bat instances for different distro/target configurations in parallel.
+
When each build completes, the build artifacts and assorted log files and unit test result XML files will be copied to these directories:
- * builds/centos_x86
- * builds/centos_x86/logs
- * builds/centos_x64
- * builds/centos_x64/logs
- * builds/ubuntu_x86
- * builds/ubuntu_x86/logs
- * builds/ubuntu_x64
- * builds/ubuntu_x64/logs
+ * builds/$distro_$target
+ * builds/$distro_$target/logs
-For CentOS, the build will produce tarballs of FDO and MapGuide along with the necessary install scripts
-For Ubuntu, the build will produce debian package files of FDO and MapGuide along with the necessary install scripts
+For Ubuntu builds, the build will produce debian package files (*.deb) of FDO and MapGuide along with the necessary install scripts
+For non-Ubuntu builds, the build will produce xz-compressed tarballs (*.tar.xz) of FDO and MapGuide along with the necessary install scripts
-At the end of the run, updated MapGuide and FDO source tarballs will be in sources/updated. You can move these tarballs up one level and
-overwrite the existing copies to ensure you have the most updated checkouts for the next build run.
+Updating MapGuide/FDO sources
+=============================
+Run update_sources.bat to update the MapGuide/FDO tarballs under the sources directory to the HEAD revisions of their respective branches.
+
+This will spin up a special centos6 VM to:
+
+ 1. Extract the MapGuide/FDO tarballs
+ 2. svn update the extracted working directories
+ 3. Re-package the working directories into new tarballs
+ 4. Overwrite the old tarballs under sources directories with the updated copies
+
Troubleshooting
===============
@@ -71,9 +104,6 @@
When doing branched releases, the following files have to be modified and their respective MapGuide and FDO versions and branch names updated to match:
- - centos\x64\Vagrantfile
- - centos\x86\Vagrantfile
- - ubuntu\x64\Vagrantfile
- - ubuntu\x86\Vagrantfile
+ - $distro\$arch\Vagrantfile
- scripts\mapguidecommon_excludes.txt
- scripts\platformbase_excludes.txt
Deleted: branches/3.0/vagrant/build.bat
===================================================================
--- branches/3.0/vagrant/build.bat 2016-05-10 12:47:30 UTC (rev 8948)
+++ branches/3.0/vagrant/build.bat 2016-05-10 13:15:13 UTC (rev 8949)
@@ -1,209 +0,0 @@
- at echo off
-
-rem build.bat
-rem
-rem Builds MapGuide/FDO in CentOS and Ubuntu VMs all driven by vagrant
-rem
-rem NOTE: CentOS builds must *always* precede the Ubuntu builds as Ubuntu builds may depend
-rem on the package FDO SDK tarball produced by the CentOS build
-rem
-rem Requires the tee utility, which is part of GNU on Windows (https://github.com/bmatzelle/gow)
-
-IF "%MG_SVN_UPDATE_SOURCES%"=="" SET MG_SVN_UPDATE_SOURCES=1
-IF "%BUILD_UBUNTU_32%"=="" SET BUILD_UBUNTU_32=1
-IF "%BUILD_UBUNTU_64%"=="" SET BUILD_UBUNTU_64=1
-IF "%BUILD_CENTOS_32%"=="" SET BUILD_CENTOS_32=1
-IF "%BUILD_CENTOS_64%"=="" SET BUILD_CENTOS_64=1
-IF "%TEARDOWN_UBUNTU_32%"=="" SET TEARDOWN_UBUNTU_32=1
-IF "%TEARDOWN_UBUNTU_64%"=="" SET TEARDOWN_UBUNTU_64=1
-IF "%TEARDOWN_CENTOS_32%"=="" SET TEARDOWN_CENTOS_32=1
-IF "%TEARDOWN_CENTOS_64%"=="" SET TEARDOWN_CENTOS_64=1
-SET ROOT=%CD%
-SET COMPONENT=
-echo **************** Build Summary *********************
-echo Update Sources: %MG_SVN_UPDATE_SOURCES%
-echo Building Ubuntu (32-bit): %BUILD_UBUNTU_32% (teardown=%TEARDOWN_UBUNTU_32%)
-echo Building Ubuntu (64-bit): %BUILD_UBUNTU_64% (teardown=%TEARDOWN_UBUNTU_64%)
-echo Building CentOS (32-bit): %BUILD_CENTOS_32% (teardown=%TEARDOWN_CENTOS_32%)
-echo Building CentOS (64-bit): %BUILD_CENTOS_64% (teardown=%TEARDOWN_CENTOS_64%)
-echo ****************************************************
-:prepare
-echo [build]: Prepare scripts for provisioning
-copy /Y scripts\svn_update.sh %ROOT%\centos\src_update
-if %BUILD_CENTOS_32% == 1 xcopy /S /Y /I scripts\* %ROOT%\centos\x86
-if %BUILD_UBUNTU_32% == 1 xcopy /S /Y /I scripts\* %ROOT%\ubuntu\x86
-if %BUILD_CENTOS_64% == 1 xcopy /S /Y /I scripts\* %ROOT%\centos\x64
-if %BUILD_UBUNTU_64% == 1 xcopy /S /Y /I scripts\* %ROOT%\ubuntu\x64
-echo [build]: Prepare build artifact location
-if not exist builds mkdir builds
-if not exist builds\centos_x86 mkdir builds\centos_x86
-if not exist builds\centos_x64 mkdir builds\centos_x64
-if not exist builds\ubuntu_x86 mkdir builds\ubuntu_x86
-if not exist builds\ubuntu_x64 mkdir builds\ubuntu_x64
-if not exist builds\centos_x86\logs mkdir builds\centos_x86\logs
-if not exist builds\centos_x64\logs mkdir builds\centos_x64\logs
-if not exist builds\ubuntu_x86\logs mkdir builds\ubuntu_x86\logs
-if not exist builds\ubuntu_x64\logs mkdir builds\ubuntu_x64\logs
-echo [build]: Checking if we're updating sources
-if %MG_SVN_UPDATE_SOURCES% == 1 goto update_sources
-goto check_centos_32
-:update_sources
-SET COMPONENT=Update MapGuide and FDO tarballs
-pushd sources
-if exist updated rd /S /Q updated
-popd
-pushd centos\src_update
-call vagrant up 2>&1 | tee up.log
-echo [build]: vagrant returned %errorlevel%
-if "%errorlevel%"=="1" goto error
-call vagrant destroy -f
-popd
-pushd sources\updated
-move /Y *.tar.gz ..
-echo [build]: Sources updated
-popd
-:check_centos_32
-echo [build]: Checking if we're building for CentOS 32-bit
-if %BUILD_CENTOS_32% == 1 goto build_centos_32
-goto check_ubuntu_32
-:build_centos_32
-pushd centos\x86
-SET COMPONENT=CentOS Build 32-bit
-echo [build]: MapGuide CentOS build 32-bit
-if exist build rd /S /Q build
-call vagrant up 2>&1 | tee up.log
-echo [build]: vagrant returned %errorlevel%
-if "%errorlevel%"=="1" goto error
-if not exist build\*.tar.xz goto error
-echo [build]: Move artifacts to build output
-move /Y build\*.sh %ROOT%\builds\centos_x86
-move /Y build\*.tar.xz %ROOT%\builds\centos_x86
-move /Y build\*.log %ROOT%\builds\centos_x86\logs
-move /Y build\*.xml %ROOT%\builds\centos_x86\logs
-echo [build]: Generate MD5 hashes
-pushd %ROOT%\builds\centos_x86
-if exist md5sums.txt del md5sums.txt
-md5sum *.sh > md5sums.txt
-md5sum *.tar.xz >> md5sums.txt
-popd
-if %TEARDOWN_CENTOS_32% == 1 (
- echo [build]: Tearing down CentOS 32 VM
- goto destroy_centos_32
-) else (
- echo [build]: Not tearing down CentOS 32 VM
- goto centos_32_done
-)
-:destroy_centos_32
-call vagrant destroy -f
-:centos_32_done
-popd
-:check_ubuntu_32
-echo [build]: Checking if we're building for Ubuntu 32-bit
-if %BUILD_UBUNTU_32% == 1 goto build_ubuntu_32
-goto check_centos_64
-:build_ubuntu_32
-pushd ubuntu\x86
-SET COMPONENT=Ubuntu Build 32-bit
-echo [build]: MapGuide Ubuntu build 32-bit
-if exist build rd /S /Q build
-call vagrant up 2>&1 | tee up.log
-echo [build]: vagrant returned %errorlevel%
-if "%errorlevel%"=="1" goto error
-if not exist build\*.deb goto error
-echo [build]: Move artifacts to build output
-move /Y build\*.sh %ROOT%\builds\ubuntu_x86
-move /Y build\*.deb %ROOT%\builds\ubuntu_x86
-move /Y build\*.log %ROOT%\builds\ubuntu_x86\logs
-move /Y build\*.xml %ROOT%\builds\ubuntu_x86\logs
-echo [build]: Generate MD5 hashes
-pushd %ROOT%\builds\ubuntu_x86
-if exist md5sums.txt del md5sums.txt
-md5sum *.sh > md5sums.txt
-md5sum *.deb >> md5sums.txt
-popd
-if %TEARDOWN_UBUNTU_32% == 1 (
- echo [build]: Tearing down Ubuntu 32 VM
- goto destroy_ubuntu_32
-) else (
- echo [build]: Not tearing down Ubuntu 32 VM
- goto ubuntu_32_done
-)
-:destroy_ubuntu_32
-call vagrant destroy -f
-:ubuntu_32_done
-popd
-:check_centos_64
-echo [build]: Checking if we're building for CentOS 64-bit
-if %BUILD_CENTOS_64% == 1 goto build_centos_64
-goto check_ubuntu_64
-:build_centos_64
-pushd centos\x64
-SET COMPONENT=CentOS Build 64-bit
-echo [build]: MapGuide CentOS build 64-bit
-if exist build rd /S /Q build
-call vagrant up 2>&1 | tee up.log
-echo [build]: vagrant returned %errorlevel%
-if "%errorlevel%"=="1" goto error
-if not exist build\*.tar.xz goto error
-echo [build]: Move artifacts to build output
-move /Y build\*.sh %ROOT%\builds\centos_x64
-move /Y build\*.tar.xz %ROOT%\builds\centos_x64
-move /Y build\*.log %ROOT%\builds\centos_x64\logs
-move /Y build\*.xml %ROOT%\builds\centos_x64\logs
-echo [build]: Generate MD5 hashes
-pushd %ROOT%\builds\centos_x64
-if exist md5sums.txt del md5sums.txt
-md5sum *.sh > md5sums.txt
-md5sum *.tar.xz >> md5sums.txt
-popd
-if %TEARDOWN_CENTOS_64% == 1 (
- echo [build]: Tearing down CentOS 64 VM
- goto destroy_centos_64
-) else (
- echo [build]: Not tearing down CentOS 64 VM
- goto centos_64_done
-)
-:destroy_centos_64
-call vagrant destroy -f
-:centos_64_done
-popd
-:check_ubuntu_64
-echo [build]: Checking if we're building for Ubuntu 64-bit
-if %BUILD_UBUNTU_64% == 1 goto build_ubuntu_64
-goto quit
-:build_ubuntu_64
-pushd ubuntu\x64
-SET COMPONENT=Ubuntu Build 64-bit
-echo [build]: MapGuide Ubuntu build 64-bit
-if exist build rd /S /Q build
-call vagrant up 2>&1 | tee up.log
-echo [build]: vagrant returned %errorlevel%
-if "%errorlevel%"=="1" goto error
-if not exist build\*.deb goto error
-echo [build]: Move artifacts to build output
-move /Y build\*.sh %ROOT%\builds\ubuntu_x64
-move /Y build\*.deb %ROOT%\builds\ubuntu_x64
-move /Y build\*.log %ROOT%\builds\ubuntu_x64\logs
-move /Y build\*.xml %ROOT%\builds\ubuntu_x64\logs
-echo [build]: Generate MD5 hashes
-pushd %ROOT%\builds\ubuntu_x64
-if exist md5sums.txt del md5sums.txt
-md5sum *.sh > md5sums.txt
-md5sum *.deb >> md5sums.txt
-popd
-if %TEARDOWN_UBUNTU_64% == 1 (
- echo [build]: Tearing down Ubuntu 64 VM
- goto destroy_ubuntu_64
-) else (
- echo [build]: Not tearing down Ubuntu 64 VM
- goto ubuntu_64_done
-)
-:destroy_ubuntu_64
-call vagrant destroy -f
-:ubuntu_64_done
-popd
-goto quit
-:error
-echo [ERROR]: There was an error building the component %COMPONENT%
-exit /B 1
-:quit
\ No newline at end of file
Copied: branches/3.0/vagrant/build_target.bat (from rev 8946, trunk/Tools/Vagrant/build_target.bat)
===================================================================
--- branches/3.0/vagrant/build_target.bat (rev 0)
+++ branches/3.0/vagrant/build_target.bat 2016-05-10 13:15:13 UTC (rev 8949)
@@ -0,0 +1,151 @@
+ at echo off
+
+rem ==================================================
+rem build_target.bat
+rem
+rem Builds MapGuide/FDO in a specific vagrant VM
+rem
+rem Requires the tee and md5sum utilities, which is
+rem part of GNU on Windows
+rem
+rem https://github.com/bmatzelle/gow
+rem
+rem ==================================================
+
+rem ==================================================
+rem Parameter Handling
+rem ==================================================
+
+:study_params
+if (%1)==() goto start_build
+
+if "%1"=="-h" goto help_show
+if "%1"=="-distro" goto get_distro
+if "%1"=="-target" goto get_target
+if "%1"=="-ext" goto get_extension
+if "%1"=="-teardown" goto get_teardown
+goto custom_error
+
+:next_param
+shift
+shift
+goto study_params
+
+:get_distro
+SET VM_DISTRO=%2
+goto next_param
+
+:get_target
+SET VM_TARGET=%2
+IF "%2"=="x86" goto next_param
+IF "%2"=="x64" goto next_param
+SET ERRORMSG=Unrecognised target: %2
+goto custom_error
+
+:get_extension
+SET BUILD_ARTIFACT_EXTENSION=%2
+IF "%2"=="deb" goto next_param
+IF "%2"=="tar.xz" goto next_param
+SET ERRORMSG=Unrecognised extension: %2
+goto custom_error
+
+:get_teardown
+SET VM_TEARDOWN=%2
+IF "%2"=="1" goto next_param
+IF "%2"=="0" goto next_param
+SET ERRORMSG=Teardown flag must be 1 or 0. Got: %2
+goto custom_error
+
+:start_build
+IF "%VM_DISTRO%"=="" goto help_show
+IF "%VM_TARGET%"=="" goto help_show
+IF "%VM_TEARDOWN%"=="" goto help_show
+IF "%BUILD_ARTIFACT_EXTENSION%"=="" goto help_show
+
+SET BUILD_ARTIFACT_DIR=builds\%VM_DISTRO%_%VM_TARGET%
+SET BUILD_LOG_DIR=%BUILD_ARTIFACT_DIR%\logs
+SET VAGRANTFILE_DIR=%VM_DISTRO%\%VM_TARGET%
+SET BUILD_ARTIFACT_SRC_DIR=%VAGRANTFILE_DIR%\build
+
+IF NOT EXIST %VAGRANTFILE_DIR% (
+ SET ERRORMSG=No vagrantfile exists at [%VAGRANTFILE_DIR%]
+ goto custom_error
+)
+
+rem Ensure build artifact dir exists
+IF NOT EXIST builds mkdir builds
+IF NOT EXIST %BUILD_ARTIFACT_DIR% mkdir %BUILD_ARTIFACT_DIR%
+IF NOT EXIST %BUILD_LOG_DIR% mkdir %BUILD_LOG_DIR%
+
+echo ***************** VM Build Summary *********************
+echo Distro: %VM_DISTRO%
+echo Target: %VM_TARGET%
+echo Teardown?: %VM_TEARDOWN%
+echo Artifact Extension: %BUILD_ARTIFACT_EXTENSION%
+echo Using vagrantfile from: %VAGRANTFILE_DIR%
+echo Build Artifacts will be in: %BUILD_ARTIFACT_DIR%
+echo ********************************************************
+
+rem Copy build/provisioning scripts to vagrantfile dir
+xcopy /S /Y /I scripts\* %VAGRANTFILE_DIR%
+
+:spin_up_vm
+echo [build]: Spin up VM at [%VAGRANTFILE_DIR%]
+pushd %VAGRANTFILE_DIR%
+if exist build rd /S /Q build
+call vagrant up 2>&1 | tee up.log
+echo [build]: vagrant returned %errorlevel%
+if "%errorlevel%"=="1" goto error
+if not exist build\*.%BUILD_ARTIFACT_EXTENSION% goto error
+popd
+goto copy_artifacts
+
+:copy_artifacts
+echo [build]: Copying artifacts from [%BUILD_ARTIFACT_SRC_DIR%] to [%BUILD_ARTIFACT_DIR%]
+move /Y %BUILD_ARTIFACT_SRC_DIR%\*.sh %BUILD_ARTIFACT_DIR%
+move /Y %BUILD_ARTIFACT_SRC_DIR%\*.%BUILD_ARTIFACT_EXTENSION% %BUILD_ARTIFACT_DIR%
+echo [build]: Copying logs from [%BUILD_ARTIFACT_SRC_DIR%] to [%BUILD_LOG_DIR%]
+move /Y %BUILD_ARTIFACT_SRC_DIR%\*.log %BUILD_LOG_DIR%
+move /Y %BUILD_ARTIFACT_SRC_DIR%\*.xml %BUILD_LOG_DIR%
+echo [build]: Generate MD5 hashes in [%BUILD_ARTIFACT_DIR%]
+pushd %BUILD_ARTIFACT_DIR%
+if exist md5sums.txt del md5sums.txt
+md5sum *.sh > md5sums.txt
+md5sum *.%BUILD_ARTIFACT_EXTENSION% >> md5sums.txt
+popd
+IF "%VM_TEARDOWN%"=="1" goto tear_down_vm
+goto quit
+
+:tear_down_vm
+echo [build]: Tear down VM at [%VAGRANTFILE_DIR%]
+pushd %VAGRANTFILE_DIR%
+call vagrant destroy -f
+popd
+goto quit
+
+:error
+echo [ERROR]: There was an error building the component
+exit /B 1
+:custom_error
+echo [ERROR]: %ERRORMSG%
+SET ERRORMSG=
+:help_show
+echo Usage:
+echo ************************************************************************
+echo build.bat [-h]
+echo [-distro=Distro]
+echo [-target=TargetName]
+echo [-ext=Extension]
+echo [-teardown=Teardown]
+echo Help: -h
+echo Distro: -distro=ubuntu12,
+echo ubuntu14
+echo centos6
+echo TargetName: -target=x86,
+echo x64
+echo Extension: -ext=deb,
+echo tar.xz
+echo Teardown: -teardown=1,
+echo 0
+echo ************************************************************************
+:quit
\ No newline at end of file
Modified: branches/3.0/vagrant/centos6/src_update/Vagrantfile
===================================================================
--- trunk/Tools/Vagrant/centos6/src_update/Vagrantfile 2016-05-10 12:11:09 UTC (rev 8946)
+++ branches/3.0/vagrant/centos6/src_update/Vagrantfile 2016-05-10 13:15:13 UTC (rev 8949)
@@ -119,5 +119,5 @@
config.vm.provision "shell",
privileged: false,
path: "svn_update.sh",
- args: ["trunk", "trunk"]
+ args: ["4.0", "3.0"]
end
Modified: branches/3.0/vagrant/centos6/x64/Vagrantfile
===================================================================
--- trunk/Tools/Vagrant/centos6/x64/Vagrantfile 2016-05-10 12:11:09 UTC (rev 8946)
+++ branches/3.0/vagrant/centos6/x64/Vagrantfile 2016-05-10 13:15:13 UTC (rev 8949)
@@ -119,5 +119,5 @@
config.vm.provision "shell",
privileged: false,
path: "provision_centos.sh",
- args: [4, 1, 0, 3, 1, 0, "trunk", "trunk", "amd64", "Test", "centos6", 1, 1]
+ args: [4, 0, 0, 3, 0, 1, "4.0", "3.0", "amd64", "Final", "centos6", 1, 1]
end
Modified: branches/3.0/vagrant/centos6/x86/Vagrantfile
===================================================================
--- trunk/Tools/Vagrant/centos6/x86/Vagrantfile 2016-05-10 12:11:09 UTC (rev 8946)
+++ branches/3.0/vagrant/centos6/x86/Vagrantfile 2016-05-10 13:15:13 UTC (rev 8949)
@@ -119,5 +119,5 @@
config.vm.provision "shell",
privileged: false,
path: "provision_centos.sh",
- args: [4, 1, 0, 3, 1, 0, "trunk", "trunk", "i386", "Test", "centos6", 1, 1]
+ args: [4, 0, 0, 3, 0, 1, "4.0", "3.0", "i386", "Final", "centos6", 1, 1]
end
Modified: branches/3.0/vagrant/make_boxes.bat
===================================================================
--- branches/3.0/vagrant/make_boxes.bat 2016-05-10 12:47:30 UTC (rev 8948)
+++ branches/3.0/vagrant/make_boxes.bat 2016-05-10 13:15:13 UTC (rev 8949)
@@ -1,35 +1,51 @@
@echo off
-SET BUILD_UBUNTU_32=1
-SET BUILD_UBUNTU_64=1
-SET BUILD_CENTOS_32=1
-SET BUILD_CENTOS_64=1
+SET BUILD_UBUNTU14_32=1
+SET BUILD_UBUNTU14_64=1
+SET BUILD_UBUNTU12_32=1
+SET BUILD_UBUNTU12_64=1
+SET BUILD_CENTOS6_32=1
+SET BUILD_CENTOS6_64=1
pushd packer
-if "%BUILD_CENTOS_64%" == "1" (
-echo [packer]: Build CentOS 64-bit base box
-packer build -force centos6-amd64.json | tee packer_centos64.log
+if "%BUILD_CENTOS6_64%" == "1" (
+echo [packer]: Build CentOS6 64-bit base box
+packer build -force centos6-amd64.json | tee packer_centos6_64.log
echo [vagrant]: Export centos6-amd64 base box
rem call vagrant package --base "centos6-amd64" --output centos6-amd64.box
call vagrant box add "centos6-amd64" centos6-amd64.box --force
)
-if "%BUILD_CENTOS_32%" == "1" (
-echo [packer]: Build CentOS 32-bit base box
-packer build -force centos6-i386.json | tee packer_centos32.log
+if "%BUILD_CENTOS6_32%" == "1" (
+echo [packer]: Build CentOS6 32-bit base box
+packer build -force centos6-i386.json | tee packer_centos6_32.log
echo [vagrant]: Export centos6-i386 base box
rem call vagrant package --base "centos6-i386" --output centos6-i386.box
call vagrant box add "centos6-i386" centos6-i386.box --force
)
-if "%BUILD_UBUNTU_64%" == "1" (
-echo [packer]: Build Ubuntu 64-bit base box
-packer build -force ubuntu12-amd64.json | tee packer_ubuntu64.log
+if "%BUILD_UBUNTU12_64%" == "1" (
+echo [packer]: Build Ubuntu12 64-bit base box
+packer build -force ubuntu12-amd64.json | tee packer_ubuntu12_64.log
echo [vagrant]: Export ubuntu12-amd64 base box
rem call vagrant package --base "ubuntu12-amd64" --output ubuntu12-amd64.box
call vagrant box add "ubuntu12-amd64" ubuntu12-amd64.box --force
)
-if "%BUILD_UBUNTU_32%" == "1" (
-echo [packer]: Build Ubuntu 32-bit base box
-packer build -force ubuntu12-i386.json | tee packer_ubuntu32.log
+if "%BUILD_UBUNTU12_32%" == "1" (
+echo [packer]: Build Ubuntu12 32-bit base box
+packer build -force ubuntu12-i386.json | tee packer_ubuntu12_32.log
echo [vagrant]: Export ubuntu12-i386 base box
rem call vagrant package --base "ubuntu12-i386" --output ubuntu12-i386.box
call vagrant box add "ubuntu12-i386" ubuntu12-i386.box --force
)
+if "%BUILD_UBUNTU14_64%" == "1" (
+echo [packer]: Build Ubuntu14 64-bit base box
+packer build -force ubuntu14-amd64.json | tee packer_ubuntu14_64.log
+echo [vagrant]: Export ubuntu14-amd64 base box
+rem call vagrant package --base "ubuntu14-amd64" --output ubuntu14-amd64.box
+call vagrant box add "ubuntu14-amd64" ubuntu14-amd64.box --force
+)
+if "%BUILD_UBUNTU14_32%" == "1" (
+echo [packer]: Build Ubuntu14 32-bit base box
+packer build -force ubuntu14-i386.json | tee packer_ubuntu14_32.log
+echo [vagrant]: Export ubuntu14-i386 base box
+rem call vagrant package --base "ubuntu14-i386" --output ubuntu14-i386.box
+call vagrant box add "ubuntu14-i386" ubuntu14-i386.box --force
+)
popd
\ No newline at end of file
Copied: branches/3.0/vagrant/packer/README.txt (from rev 8947, trunk/Tools/Vagrant/packer/README.txt)
===================================================================
--- branches/3.0/vagrant/packer/README.txt (rev 0)
+++ branches/3.0/vagrant/packer/README.txt 2016-05-10 13:15:13 UTC (rev 8949)
@@ -0,0 +1,7 @@
+This directory contains packer templates to produce vagrant base boxes for MapGuide
+
+ * CentOS 6.5 (x86/x64)
+ * Ubuntu 12.04.5 (x86/x64)
+ * Ubuntu 14.04.4 (x86/x64)
+
+Based on packer templates at: https://github.com/kaorimatz/packer-templates
\ No newline at end of file
Copied: branches/3.0/vagrant/packer/ubuntu14-amd64.json (from rev 8946, trunk/Tools/Vagrant/packer/ubuntu14-amd64.json)
===================================================================
--- branches/3.0/vagrant/packer/ubuntu14-amd64.json (rev 0)
+++ branches/3.0/vagrant/packer/ubuntu14-amd64.json 2016-05-10 13:15:13 UTC (rev 8949)
@@ -0,0 +1,59 @@
+{
+ "builders": [{
+ "type": "virtualbox-iso",
+ "guest_os_type": "Ubuntu_64",
+ "iso_url": "http://mirror.internode.on.net.au/pub/ubuntu/releases/14.04/ubuntu-14.04.4-server-amd64.iso",
+ "iso_checksum": "2ac1f3e0de626e54d05065d6f549fa3a",
+ "iso_checksum_type": "md5",
+ "output_directory": "output-ubuntu-14.04.4-amd64",
+ "vm_name": "packer-ubuntu-14.04.4-amd64",
+ "disk_size": "{{user `disk_size`}}",
+ "headless": "{{user `headless`}}",
+ "http_directory": "http",
+ "boot_wait": "5s",
+ "boot_command": [
+ "<esc><wait>",
+ "<esc><wait>",
+ "<enter><wait>",
+ "/install/vmlinuz ",
+ "initrd=/install/initrd.gz ",
+ "biosdevname=0 ",
+ "auto-install/enable=true ",
+ "debconf/priority=critical ",
+ "preseed/url=http://{{.HTTPIP}}:{{.HTTPPort}}/ubuntu-14.04.4/preseed.cfg ",
+ "<enter>"
+ ],
+ "ssh_wait_timeout": "60m",
+ "ssh_username": "vagrant",
+ "ssh_password": "vagrant",
+ "shutdown_command": "sudo poweroff",
+ "vboxmanage": [
+ ["modifyvm", "{{.Name}}", "--memory", "{{user `memory`}}"],
+ ["modifyvm", "{{.Name}}", "--cpus", "{{user `cpus`}}"]
+ ]
+ }],
+ "provisioners": [{
+ "type": "shell",
+ "scripts": [
+ "scripts/ubuntu/base.sh",
+ "scripts/ubuntu/virtualbox.sh",
+ "scripts/common/vagrant.sh",
+ "scripts/common/sshd.sh",
+ "scripts/mapguide/ubuntu64.sh",
+ "scripts/ubuntu/cleanup.sh",
+ "scripts/common/minimize.sh"
+ ]
+ }],
+ "post-processors": [{
+ "type": "vagrant",
+ "compression_level": "{{user `compression_level`}}",
+ "output": "ubuntu14-amd64.box"
+ }],
+ "variables": {
+ "compression_level": 1,
+ "cpus": "2",
+ "disk_size": 25000,
+ "headless": false,
+ "memory": "1024"
+ }
+}
Copied: branches/3.0/vagrant/packer/ubuntu14-i386.json (from rev 8946, trunk/Tools/Vagrant/packer/ubuntu14-i386.json)
===================================================================
--- branches/3.0/vagrant/packer/ubuntu14-i386.json (rev 0)
+++ branches/3.0/vagrant/packer/ubuntu14-i386.json 2016-05-10 13:15:13 UTC (rev 8949)
@@ -0,0 +1,59 @@
+{
+ "builders": [{
+ "type": "virtualbox-iso",
+ "guest_os_type": "Ubuntu",
+ "iso_url": "http://mirror.internode.on.net.au/pub/ubuntu/releases/14.04/ubuntu-14.04.4-server-i386.iso",
+ "iso_checksum": "29c5c14450976fb1941e147382a559f5",
+ "iso_checksum_type": "md5",
+ "output_directory": "output-ubuntu-14.04.4-i386",
+ "vm_name": "packer-ubuntu-14.04.4-i386",
+ "disk_size": "{{user `disk_size`}}",
+ "headless": "{{user `headless`}}",
+ "http_directory": "http",
+ "boot_wait": "5s",
+ "boot_command": [
+ "<esc><wait>",
+ "<esc><wait>",
+ "<enter><wait>",
+ "/install/vmlinuz ",
+ "initrd=/install/initrd.gz ",
+ "biosdevname=0 ",
+ "auto-install/enable=true ",
+ "debconf/priority=critical ",
+ "preseed/url=http://{{.HTTPIP}}:{{.HTTPPort}}/ubuntu-14.04.4/preseed.cfg ",
+ "<enter>"
+ ],
+ "ssh_wait_timeout": "60m",
+ "ssh_username": "vagrant",
+ "ssh_password": "vagrant",
+ "shutdown_command": "sudo poweroff",
+ "vboxmanage": [
+ ["modifyvm", "{{.Name}}", "--memory", "{{user `memory`}}"],
+ ["modifyvm", "{{.Name}}", "--cpus", "{{user `cpus`}}"]
+ ]
+ }],
+ "provisioners": [{
+ "type": "shell",
+ "scripts": [
+ "scripts/ubuntu/base.sh",
+ "scripts/ubuntu/virtualbox.sh",
+ "scripts/common/vagrant.sh",
+ "scripts/common/sshd.sh",
+ "scripts/mapguide/ubuntu32.sh",
+ "scripts/ubuntu/cleanup.sh",
+ "scripts/common/minimize.sh"
+ ]
+ }],
+ "post-processors": [{
+ "type": "vagrant",
+ "compression_level": "{{user `compression_level`}}",
+ "output": "ubuntu14-i386.box"
+ }],
+ "variables": {
+ "compression_level": 1,
+ "cpus": "2",
+ "disk_size": 25000,
+ "headless": false,
+ "memory": "1024"
+ }
+}
Modified: branches/3.0/vagrant/scripts/provision_centos.sh
===================================================================
--- branches/3.0/vagrant/scripts/provision_centos.sh 2016-05-10 12:47:30 UTC (rev 8948)
+++ branches/3.0/vagrant/scripts/provision_centos.sh 2016-05-10 13:15:13 UTC (rev 8949)
@@ -318,7 +318,7 @@
for comp in CoordinateSystem
do
BUILD_COMPONENT="Unit Test MapGuide Server ($comp)"
- sudo -E timeout 20m ./mgserver test $comp UnitTestResults_${comp}.xml 2>&1 | tee $MG_HOME/mapguide_${comp}_unit_test.log
+ sudo -E timeout 40m ./mgserver test $comp UnitTestResults_${comp}.xml 2>&1 | tee $MG_HOME/mapguide_${comp}_unit_test.log
check_server_test
if [ -f UnitTestResults_${comp}.xml ]; then
sudo mv UnitTestResults_${comp}.xml $MG_HOME/UnitTestResults_${comp}.xml
Modified: branches/3.0/vagrant/scripts/provision_ubuntu.sh
===================================================================
--- branches/3.0/vagrant/scripts/provision_ubuntu.sh 2016-05-10 12:47:30 UTC (rev 8948)
+++ branches/3.0/vagrant/scripts/provision_ubuntu.sh 2016-05-10 13:15:13 UTC (rev 8949)
@@ -267,7 +267,7 @@
FDO_REV=`svn info $FDO_SRC | perl revnum.pl`
MG_REV=`svn info $MG_SRC | perl revnum.pl`
BUILD_COMPONENT="MapGuide deb packages"
-./dpkgmapguide.sh $MG_ARCH $MG_REV 2>&1 | tee $MG_HOME/dpkg_mapguide.log
+sudo -E ./dpkgmapguide.sh $MG_ARCH $MG_REV 2>&1 | tee $MG_HOME/dpkg_mapguide.log
check_build
> $MG_HOME/unit_test_status.log
if [ $FDO_UNIT_TEST -eq 1 ];
@@ -328,7 +328,7 @@
for comp in CoordinateSystem
do
BUILD_COMPONENT="Unit Test MapGuide Server ($comp)"
- sudo -E timeout 20m ./mgserver test $comp UnitTestResults_${comp}.xml 2>&1 | tee $MG_HOME/mapguide_${comp}_unit_test.log
+ sudo -E timeout 40m ./mgserver test $comp UnitTestResults_${comp}.xml 2>&1 | tee $MG_HOME/mapguide_${comp}_unit_test.log
check_server_test
if [ -f UnitTestResults_${comp}.xml ]; then
sudo mv UnitTestResults_${comp}.xml $MG_HOME/UnitTestResults_${comp}.xml
@@ -355,7 +355,7 @@
echo [provision]: Copy log files to output dir
sudo mv -f $MG_HOME/*.log $MOUNT_DIR/build
echo [provision]: Copy tarballs to output dir
-sudo cp bin/*.tar.xz $MOUNT_DIR/build
+# sudo cp bin/*.tar.xz $MOUNT_DIR/build
sudo cp fdosdk-${FDO_DISTRO}-${MG_ARCH}-${FDO_VER_MAJOR}.${FDO_VER_MINOR}.${FDO_VER_REV}_${FDO_REV}.tar.xz $MOUNT_DIR/build
if [ $MAKE_FDO_SDK -eq 1 ]; then
echo [provision]: Copy FDO SDK for Ubuntu builds
Modified: branches/3.0/vagrant/ubuntu12/x64/Vagrantfile
===================================================================
--- trunk/Tools/Vagrant/ubuntu12/x64/Vagrantfile 2016-05-10 12:11:09 UTC (rev 8946)
+++ branches/3.0/vagrant/ubuntu12/x64/Vagrantfile 2016-05-10 13:15:13 UTC (rev 8949)
@@ -119,5 +119,5 @@
config.vm.provision "shell",
privileged: false,
path: "provision_ubuntu.sh",
- args: [4, 1, 0, 3, 1, 0, "trunk", "trunk", "amd64", "Test", "ubuntu12", 1, 1]
+ args: [4, 0, 0, 3, 0, 1, "4.0", "3.0", "amd64", "Final", "ubuntu12", 1, 1]
end
Modified: branches/3.0/vagrant/ubuntu12/x86/Vagrantfile
===================================================================
--- trunk/Tools/Vagrant/ubuntu12/x86/Vagrantfile 2016-05-10 12:11:09 UTC (rev 8946)
+++ branches/3.0/vagrant/ubuntu12/x86/Vagrantfile 2016-05-10 13:15:13 UTC (rev 8949)
@@ -119,5 +119,5 @@
config.vm.provision "shell",
privileged: false,
path: "provision_ubuntu.sh",
- args: [4, 1, 0, 3, 1, 0, "trunk", "trunk", "i386", "Test", "ubuntu12", 1, 1]
+ args: [4, 0, 0, 3, 0, 1, "4.0", "3.0", "i386", "Final", "ubuntu12", 1, 1]
end
Modified: branches/3.0/vagrant/ubuntu14/x64/Vagrantfile
===================================================================
--- trunk/Tools/Vagrant/ubuntu14/x64/Vagrantfile 2016-05-10 12:11:09 UTC (rev 8946)
+++ branches/3.0/vagrant/ubuntu14/x64/Vagrantfile 2016-05-10 13:15:13 UTC (rev 8949)
@@ -119,5 +119,5 @@
config.vm.provision "shell",
privileged: false,
path: "provision_ubuntu.sh",
- args: [4, 1, 0, 3, 1, 0, "trunk", "trunk", "amd64", "Test", "ubuntu14", 1, 1]
+ args: [4, 0, 0, 3, 0, 1, "4.0", "3.0", "amd64", "Final", "ubuntu12", 1, 1]
end
Modified: branches/3.0/vagrant/ubuntu14/x86/Vagrantfile
===================================================================
--- trunk/Tools/Vagrant/ubuntu14/x86/Vagrantfile 2016-05-10 12:11:09 UTC (rev 8946)
+++ branches/3.0/vagrant/ubuntu14/x86/Vagrantfile 2016-05-10 13:15:13 UTC (rev 8949)
@@ -119,5 +119,5 @@
config.vm.provision "shell",
privileged: false,
path: "provision_ubuntu.sh",
- args: [4, 1, 0, 3, 1, 0, "trunk", "trunk", "i386", "Test", "ubuntu14", 1, 1]
+ args: [4, 0, 0, 3, 0, 1, "4.0", "3.0", "i386", "Final", "ubuntu12", 1, 1]
end
Copied: branches/3.0/vagrant/update_sources.bat (from rev 8946, trunk/Tools/Vagrant/update_sources.bat)
===================================================================
--- branches/3.0/vagrant/update_sources.bat (rev 0)
+++ branches/3.0/vagrant/update_sources.bat 2016-05-10 13:15:13 UTC (rev 8949)
@@ -0,0 +1,19 @@
+ at echo off
+
+rem update_sources.bat
+rem
+rem Updates MapGuide/FDO source tarballs via the src_update centos6 VM
+pushd sources
+if exist updated rd /S /Q updated
+popd
+copy /Y scripts\svn_update.sh centos6\src_update
+pushd centos6\src_update
+call vagrant up 2>&1 | tee up.log
+echo [src_update]: vagrant returned %errorlevel%
+if "%errorlevel%"=="1" goto error
+call vagrant destroy -f
+popd
+pushd sources\updated
+move /Y *.tar.gz ..
+echo [src_update]: Sources updated
+popd
\ No newline at end of file
More information about the mapguide-commits
mailing list