Merge lp:~fginther/vmbuilder/jenkins_kvm-artful-update into lp:~ubuntu-on-ec2/vmbuilder/jenkins_kvm

Proposed by Francis Ginther
Status: Merged
Merged at revision: 793
Proposed branch: lp:~fginther/vmbuilder/jenkins_kvm-artful-update
Merge into: lp:~ubuntu-on-ec2/vmbuilder/jenkins_kvm
Diff against target: 134 lines (+41/-46)
2 files modified
jenkins/CloudImages_Update_Builder.sh (+2/-2)
templates/img-update.tmpl (+39/-44)
To merge this branch: bzr merge lp:~fginther/vmbuilder/jenkins_kvm-artful-update
Reviewer Review Type Date Requested Status
Ubuntu on EC2 Pending
Review via email: mp+332056@code.launchpad.net

Commit message

Update CloudImages_Update_Builder.sh to use zesty images for artful and newer builds and drop installation of ubuntu-device-flash. Also remove references to precise in the builder script and template.

Description of the change

Update CloudImages_Update_Builder.sh to use zesty images for artful and newer builds and drop installation of ubuntu-device-flash. Also remove references to precise in the builder script and template.

To post a comment you must log in.
791. By Francis Ginther

Try with yakkety images.

792. By Francis Ginther

Use a zesty builder.

793. By Francis Ginther

Fix missing .

794. By Francis Ginther

Fix zfs install.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'jenkins/CloudImages_Update_Builder.sh'
2--- jenkins/CloudImages_Update_Builder.sh 2016-08-03 10:33:46 +0000
3+++ jenkins/CloudImages_Update_Builder.sh 2017-10-18 20:55:35 +0000
4@@ -18,13 +18,13 @@
5
6 # Copy the target disk image
7 case ${SUITE} in
8- precise|trusty|wily|xenial)
9+ trusty|xenial|zesty)
10 disk_orig="${SUITE}-server-cloudimg-${ARCH}-disk1.img"
11 builder_img=/srv/builder/images/trusty-builder-latest.img
12 ;;
13 *)
14 disk_orig="${SUITE}-server-cloudimg-${ARCH}.img"
15- builder_img=/srv/builder/images/yakkety-builder-latest.img
16+ builder_img=/srv/builder/images/zesty-builder-latest.img
17 ;;
18 esac
19
20
21=== modified file 'templates/img-update.tmpl'
22--- templates/img-update.tmpl 2017-10-10 22:34:03 +0000
23+++ templates/img-update.tmpl 2017-10-18 20:55:35 +0000
24@@ -44,14 +44,6 @@
25
26 [ "${dev_uuid}" == "${odev_uuid}" ] && fail "device ID's are the same. This is bad"
27
28-# dist_ge(dist1,dist2)
29-# return true if dist1 is newer or the same as dist2
30-dist_ge() { [[ "$1" > "$2" || "$1" == "$2" ]]; }
31-
32-# dist_ge(dist1,dist2)
33-# return true if dist2 is older than or the same as dist2
34-dist_le() { [[ "$1" < "$2" || "$1" == "$2" ]]; }
35-
36 operation_files() {
37
38 for i in $(seq 0 $((${#file_list[@]} - 1)))
39@@ -210,28 +202,29 @@
40 dkms
41 git)
42
43-if [ "${suite}" == "precise" ]; then
44- pkgs+=(linux-source-3.2.0 qemu-kvm-extras qemu-kvm-extras-static)
45-else
46- case "${suite}" in
47- trusty|xenial) # not for yakkety onward
48- xchroot apt-add-repository -y ppa:snappy-dev/tools
49- xchroot apt-add-repository -y ppa:ubuntu-sdk-team/ppa
50- ;;
51- esac
52- xchroot apt-add-repository -y multiverse
53- pkgs+=(qemu-user-static
54- qemu-user
55- ubuntu-device-flash
56- ubuntu-snappy-cli
57- python-openstackclient
58- cloud-utils)
59- case "${suite}" in
60- trusty|xenial)
61- pkgs+=(ubuntu-core-security-utils)
62- ;;
63- esac
64-fi
65+case "${suite}" in
66+ trusty|xenial) # not for yakkety onward
67+ xchroot apt-add-repository -y ppa:snappy-dev/tools
68+ xchroot apt-add-repository -y ppa:ubuntu-sdk-team/ppa
69+ ;;
70+esac
71+xchroot apt-add-repository -y multiverse
72+pkgs+=(qemu-user-static
73+ qemu-user
74+ ubuntu-snappy-cli
75+ python-openstackclient
76+ cloud-utils)
77+case "${suite}" in
78+ trusty|xenial)
79+ pkgs+=(ubuntu-core-security-utils)
80+ ;;
81+esac
82+# ubuntu-device-flash was dropped after zesty
83+case "${suite}" in
84+ trusty|xenial|zesty)
85+ pkgs+=(ubuntu-device-flash)
86+ ;;
87+esac
88
89 # Installation of packages
90 debug "Performing package operations"
91@@ -241,19 +234,21 @@
92 debug "Package operations complete"
93
94 # Install ZFS
95-if dist_ge ${suite} xenial; then
96- xchroot apt-get -y install zfsutils-linux
97-
98-else
99- debug "Installing ZFS"
100- xchroot apt-add-repository -y ppa:zfs-native/stable
101- xchroot apt-get update
102- xchroot apt-get -y install spl
103- xchroot dpkg-reconfigure spl
104- xchroot apt-get -y install ubuntu-zfs
105- xchroot dpkg-reconfigure dkms
106- debug "Installed ZFS"
107-fi
108+case "${suite}" in
109+ trusty)
110+ debug "Installing ZFS"
111+ xchroot apt-add-repository -y ppa:zfs-native/stable
112+ xchroot apt-get update
113+ xchroot apt-get -y install spl
114+ xchroot dpkg-reconfigure spl
115+ xchroot apt-get -y install ubuntu-zfs
116+ xchroot dpkg-reconfigure dkms
117+ debug "Installed ZFS"
118+ ;;
119+ *)
120+ xchroot apt-get -y install zfsutils-linux
121+ ;;
122+esac
123
124 # Modify boot settings
125 debug "Modifying in-image settings for builder"
126@@ -264,7 +259,7 @@
127 xchroot update-initramfs -u -k all
128 # On yakkety and later, reinstall grub-pc which is no longer in the base image
129 case $suite in
130- precise|trusty|xenial)
131+ trusty|xenial)
132 xchroot dpkg-reconfigure grub-pc
133 ;;
134 *)

Subscribers

People subscribed via source and target branches