~stephanpampel/landscape-client-charm/landscape-client-charm

« back to all changes in this revision

Viewing changes to hooks/common.py

  • Committer: Simon Poirier
  • Date: 2018-02-24 05:26:59 UTC
  • mto: This revision was merged to the branch mainline in revision 66.
  • Revision ID: simon.poirier@canonical.com-20180224052659-xz817rq1b86anqhb
make python hooks run on version used by landscape-client

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
from charmhelpers.core.hookenv import (
9
9
    log, local_unit, status_set)
10
10
 
11
 
from landscape.configuration import (
12
 
    setup, register, LandscapeSetupConfiguration, ConfigurationError,
13
 
    stop_client_and_disable_init_script)
14
 
from landscape.deployment import Configuration
15
 
from landscape.sysvconfig import SysVConfig
 
11
try:
 
12
    from landscape.client.configuration import (
 
13
        setup, register, LandscapeSetupConfiguration, ConfigurationError,
 
14
        stop_client_and_disable_init_script)
 
15
    from landscape.client.deployment import Configuration
 
16
    from landscape.client.sysvconfig import SysVConfig
 
17
except ImportError:
 
18
    from landscape.configuration import (
 
19
        setup, register, LandscapeSetupConfiguration, ConfigurationError,
 
20
        stop_client_and_disable_init_script)
 
21
    from landscape.deployment import Configuration
 
22
    from landscape.sysvconfig import SysVConfig
16
23
 
17
24
 
18
25
class JujuBroker(object):