~openstack-charmers/charms/trusty/openstack-dashboard/old-stable

« back to all changes in this revision

Viewing changes to hooks/horizon_hooks.py

  • Committer: Liam Young
  • Date: 2014-09-01 06:33:21 UTC
  • mfrom: (33.1.1 stable-no-node)
  • Revision ID: liam.young@canonical.com-20140901063321-cqtwewlflrh745em
[mwhudson,r=gnuoy] Cherry pick of fix for nodejs package deps from next

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
from charmhelpers.contrib.openstack.utils import (
23
23
    configure_installation_source,
24
24
    openstack_upgrade_available,
 
25
    os_release,
25
26
    save_script_rc
26
27
)
27
28
from horizon_utils import (
44
45
def install():
45
46
    configure_installation_source(config('openstack-origin'))
46
47
    apt_update(fatal=True)
47
 
    apt_install(filter_installed_packages(PACKAGES), fatal=True)
 
48
    packages = PACKAGES[:]
 
49
    if os_release('openstack-dashboard') < 'icehouse':
 
50
        packages += ['nodejs', 'node-less']
 
51
    apt_install(filter_installed_packages(packages), fatal=True)
48
52
 
49
53
 
50
54
@hooks.hook('upgrade-charm')