~ddellav/charms/trusty/glance/ch-upgrade-action

« back to all changes in this revision

Viewing changes to hooks/glance_utils.py

  • Committer: Edward Hope-Morley
  • Date: 2015-09-25 17:20:59 UTC
  • mfrom: (140.1.1 glance.lp1499435)
  • Revision ID: edward.hope-morley@canonical.com-20150925172059-a45lbzdcb7z4feck
[hopem,r=gnuoy]

No more trusty-backports for haproxy >= Liberty

Closes-Bug: 1499435

Show diffs side-by-side

added added

removed removed

Lines of Context:
305
305
        raise Exception("IPv6 is not supported in the charms for Ubuntu "
306
306
                        "versions less than Trusty 14.04")
307
307
 
308
 
    # NOTE(xianghui): Need to install haproxy(1.5.3) from trusty-backports
309
 
    # to support ipv6 address, so check is required to make sure not
310
 
    # breaking other versions, IPv6 only support for >= Trusty
311
 
    if ubuntu_rel == 'trusty':
312
 
        add_source('deb http://archive.ubuntu.com/ubuntu trusty-backports'
313
 
                   ' main')
 
308
    # Need haproxy >= 1.5.3 for ipv6 so for Trusty if we are <= Kilo we need to
 
309
    # use trusty-backports otherwise we can use the UCA.
 
310
    if ubuntu_rel == 'trusty' and os_release('glance') < 'liberty':
 
311
        add_source('deb http://archive.ubuntu.com/ubuntu trusty-backports '
 
312
                   'main')
314
313
        apt_update()
315
314
        apt_install('haproxy/trusty-backports', fatal=True)
316
315