~fginther/vmbuilder/jenkins_kvm-occ

« back to all changes in this revision

Viewing changes to jenkins/build_lib.sh

  • Committer: Robert C Jennings
  • Date: 2017-05-26 13:59:49 UTC
  • mfrom: (785.1.2 jenkins_kvm)
  • Revision ID: robert.jennings@canonical.com-20170526135949-vvyzl3tnlnt45knv
Build images with trusty, not precise

[a=rcj][r=philroche,tribaal]
Move to using Trusty for the builder image in all cases now that
Precise has reached End of Life and moved to S3.

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
[ -z "${DISTRO}" -a -n "${SUITE}" ] && DISTRO="${SUITE}"
17
17
 
18
18
select_build_config() {
19
 
    # Use the latest 12.04 LTS image to do the build.
20
 
    local precise_rel_img="http://cloud-images.ubuntu.com/releases/precise/release/ubuntu-12.04-server-cloudimg-amd64-disk1.img"
21
 
    local trusty_rel_img="http://cloud-images.ubuntu.com/releases/trusty/release/ubuntu-14.04-server-cloudimg-amd64-uefi1.img"
22
 
    local trusty_daily_img="http://cloud-images.ubuntu.com/trusty/current/trusty-server-cloudimg-amd64-uefi1.img"
23
 
    local use_trusty=0
24
 
    export cloud_init_cfg="cloud-precise.cfg"
25
19
 
26
20
    [ -z "${BUILDER_CLOUD_IMAGE}" ] && {
27
 
        BUILDER_CLOUD_IMAGE="${precise_rel_img}"
28
 
 
29
 
        use_trusty=${USE_TRUSTY:-0}
30
 
        dist_ge "${SUITE}" trusty && use_trusty=1
31
 
        [[ "${ARCH_TYPE}" =~ (ppc64el|arm) ]] && use_trusty=1
32
 
        [ "${use_trusty:-0}" -eq 1 ] &&  {
33
 
            echo "Using Trusty to complete this build"
34
 
            BUILDER_CLOUD_IMAGE="${trusty_rel_img}"
35
 
            export cloud_init_cfg="cloud-trusty.cfg"
36
 
 
37
 
            # TEMPORARY until 14.04 is released, but will make sure that when trusty is released
38
 
            # that the released images are used
39
 
            (curl -I "${BUILDER_CLOUD_IMAGE}" | egrep "HTTP.*200 OK")  || \
40
 
                BUILDER_CLOUD_IMAGE="${trusty_daily_img}"
41
 
            export BUILDER_CLOUD_IMAGE
42
 
        }
43
 
    }
 
21
        # Use the latest 14.04 LTS image to do the build.
 
22
        BUILDER_CLOUD_IMAGE="http://cloud-images.ubuntu.com/releases/trusty/release/ubuntu-14.04-server-cloudimg-amd64-uefi1.img"
 
23
        export cloud_init_cfg="cloud-trusty.cfg"
 
24
       }
44
25
 
45
26
    # For ppc64el, we use ppc64el images
46
27
    [ "${ARCH_TYPE}" == "ppc64el" ] && {