~adalbas/ibmcharms/gpfs-config

« back to all changes in this revision

Viewing changes to charms/trusty/gpfs/hooks/gpfshooklib.py

  • Committer: Adalberto Medeiros
  • Date: 2015-02-27 18:57:41 UTC
  • Revision ID: adalbas@linux.vnet.ibm.com-20150227185741-m4rmhxiwd4ft0lq8
Fix changes on install, config-changed and gpfshooklib
Fix quorum description on config.yaml
Added juju set configuration to README

Show diffs side-by-side

added added

removed removed

Lines of Context:
9
9
from subprocess import (
10
10
    call,
11
11
    check_call,
12
 
    check_output
 
12
    check_output,
 
13
    CalledProcessError
13
14
)
14
15
 
15
16
sys.path.insert(0, os.path.join(os.environ['CHARM_DIR'], 'lib'))
141
142
def build_modules():
142
143
# build binary gpfs modules after installation
143
144
    try:
144
 
        subprocess.check_call(["mmbuildgpl"])
145
 
    except subprocess.CalledProcessError:
 
145
        check_call(["mmbuildgpl"])
 
146
    except CalledProcessError:
146
147
        log('mmbuildgpl was not executed', level=hookenv.WARNING)
147
148
    except OSError:
148
149
        log('mmbuildgpl not found/installed')