14 from maas_deployer.vmaas.util import CONF as cfg
16 from maas_deployer.vmaas import (
23 # Setup logging before imports
25 filename='maas_deployer.log',
27 format=('%(asctime)s %(levelname)s '
28 '(%(funcName)s) %(message)s'))
30 log = logging.getLogger('vmaas.main')
31 handler = logging.StreamHandler()
32 formatter = logging.Formatter('%(asctime)s %(levelname)s %(message)s')
33 handler.setFormatter(formatter)
34 log.addHandler(handler)
38 maasipaddress = str(sys.argv);
41 sudo apt-get install git -y
42 git clone https://gerrit.opnfv.org/gerrit/joid
44 cp /home/juju/.juju/environments.yaml ~/.juju/
49 util.exec_script_remote('ubuntu', maasipaddress[1], script)
51 # Remove console handler to avoid displaying the exception twice
52 log.removeHandler(handler)
53 log.exception("MAAS deployment failed.")
56 if __name__ == '__main__':