Example #1
0
def main():
    CONF.register_cli_opt(command_opt)
    try:
        CONF(sys.argv[1:], project="heat", prog="heat-engine", version=version.version_info.version_string())
        log.setup("heat")
        db_api.configure()
    except RuntimeError as e:
        sys.exit("ERROR: %s" % e)

    try:
        CONF.command.func()
    except Exception as e:
        sys.exit("ERROR: %s" % e)
Example #2
0
def main():
    CONF.register_cli_opt(command_opt)
    try:
        default_config_files = cfg.find_config_files('heat', 'heat-engine')
        CONF(sys.argv[1:], project='heat', prog='heat-manage',
             version=version.version_info.version_string(),
             default_config_files=default_config_files)
        log.setup("heat")
        db_api.configure()
    except RuntimeError as e:
        sys.exit("ERROR: %s" % e)

    try:
        CONF.command.func()
    except Exception as e:
        sys.exit("ERROR: %s" % e)
Example #3
0
def main():
    CONF.register_cli_opt(command_opt)
    try:
        CONF(sys.argv[1:],
             project='heat',
             prog='heat-engine',
             version=version.version_info.version_string())
        log.setup("heat")
        db_api.configure()
    except RuntimeError as e:
        sys.exit("ERROR: %s" % e)

    try:
        CONF.command.func()
    except Exception as e:
        sys.exit("ERROR: %s" % e)
Example #4
0
File: sync.py Project: randres/heat
#
#    Unless required by applicable law or agreed to in writing, software
#    distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
#    License for the specific language governing permissions and limitations
#    under the License.

import gettext

import sys

gettext.install('heat', unicode=1)

from oslo.config import cfg
from heat.openstack.common import log as logging
from heat.db import api
from heat.db import migration

LOG = logging.getLogger(__name__)

if __name__ == '__main__':
    cfg.CONF(project='heat', prog='heat-engine')

    api.configure()

    try:
        migration.db_sync()
    except Exception as exc:
        print >> sys.stderr, str(exc)
        sys.exit(1)
Example #5
0
File: sync.py Project: hardys/heat
#    distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
#    License for the specific language governing permissions and limitations
#    under the License.

import gettext

import sys

gettext.install('heat', unicode=1)

from oslo.config import cfg
from heat.openstack.common import log as logging
from heat.db import api
from heat.db import migration


LOG = logging.getLogger(__name__)


if __name__ == '__main__':
    cfg.CONF(project='heat', prog='heat-engine')

    api.configure()

    try:
        migration.db_sync()
    except Exception as exc:
        print >>sys.stderr, str(exc)
        sys.exit(1)