Fix config file and apache setup
Change-Id: Ie17d7afe563d845fa75abae281da9eaaff9b4a27
This commit is contained in:
parent
3ad4ddfca8
commit
ee9bbf42b6
@ -1,33 +1,67 @@
|
||||
import os
|
||||
orm_host = '0.0.0.0'
|
||||
orm_protocal = 'http'
|
||||
orm_host = '127.0.0.1'
|
||||
log_location = '{}'
|
||||
ranger_base = os.path.dirname(os.path.abspath('orm'))
|
||||
ranger_base = '/opt/stack/upstream_ranger/ranger'
|
||||
log_location = ranger_base + '/logs/{}'
|
||||
db_user = 'root'
|
||||
db_pass = 'stack'
|
||||
db_host = '127.0.0.1'
|
||||
ssl_verify = False
|
||||
token_auth_enabled = True
|
||||
token_auth_user = 'admin'
|
||||
token_auth_pass = 'nova'
|
||||
token_auth_tenant = 'admin'
|
||||
token_auth_user_role = 'admin'
|
||||
uuid_port = 7001
|
||||
audit_port = 7002
|
||||
rms_port = 7003
|
||||
rds_port = 8777
|
||||
cms_port = 7080
|
||||
fms_port = 8082
|
||||
ims_port = 8084
|
||||
|
||||
db_url = 'mysql://' + db_user + ':' + db_pass + '@' + db_host + ':3306/'
|
||||
|
||||
uuid = {
|
||||
'port': '7001',
|
||||
'port': uuid_port,
|
||||
'base_url': '{}://{}:{}/'.format(orm_protocal, orm_host, uuid_port),
|
||||
'log': log_location.format('uuidgen.log')
|
||||
}
|
||||
cms = {
|
||||
'port': '7080',
|
||||
'port': cms_port,
|
||||
'base_url': '{}://{}:{}/'.format(orm_protocal, orm_host, cms_port),
|
||||
'policy_file': ranger_base + '/orm/services/customer_manager/cms_rest/etc/policy.json',
|
||||
'log': log_location.format('cms.log')
|
||||
}
|
||||
fms = {
|
||||
'port': '8082',
|
||||
'port': fms_port,
|
||||
'base_url': '{}://{}:{}/'.format(orm_protocal, orm_host, fms_port),
|
||||
'policy_file': ranger_base + '/orm/services/flavor_manager/fms_rest/etc/policy.json',
|
||||
'log': log_location.format('fms.log')
|
||||
}
|
||||
audit_server = {
|
||||
'port': '8776',
|
||||
'port': audit_port,
|
||||
'base_url': '{}://{}:{}/'.format(orm_protocal, orm_host, audit_port),
|
||||
'log': log_location.format('audit_server.log')
|
||||
}
|
||||
ims = {
|
||||
'port': '8084',
|
||||
'port': ims_port,
|
||||
'base_url': '{}://{}:{}/'.format(orm_protocal, orm_host, ims_port),
|
||||
'policy_file': ranger_base + '/orm/services/image_manager/ims/etc/policy.json',
|
||||
'log': log_location.format('ims.log')
|
||||
}
|
||||
rms = {
|
||||
'port': '8080',
|
||||
'port': rms_port,
|
||||
'base_url': '{}://{}:{}/'.format(orm_protocal, orm_host, rms_port),
|
||||
'policy_file': ranger_base + '/orm/services/region_manager/rms/etc/policy.json',
|
||||
'log': log_location.format('rms.log')
|
||||
}
|
||||
rds = {
|
||||
'port': '8778',
|
||||
'port': rds_port,
|
||||
'repo_local_location': '/opt/app/orm/ORM',
|
||||
'repo_user': 'orm',
|
||||
'repo_email': 'orm@test.com',
|
||||
'repo_remote_location': 'git@127.0.0.1:/home/repo/ORM.git',
|
||||
'base_url': '{}://{}:{}/'.format(orm_protocal, orm_host, rds_port),
|
||||
'log': log_location.format('rds.log')
|
||||
}
|
||||
|
@ -2,6 +2,7 @@
|
||||
import argparse
|
||||
import cli_common
|
||||
import config
|
||||
import orm.base_config as base_config
|
||||
import os
|
||||
import requests
|
||||
|
||||
@ -357,7 +358,7 @@ def get_token(timeout, args, host):
|
||||
print message
|
||||
raise cli_common.MissingArgumentError(message)
|
||||
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:8080'.format(host),
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:{}'.format(host, base_config.rms['port']),
|
||||
auth_region)
|
||||
if keystone_ep is None:
|
||||
raise ConnectionError(
|
||||
@ -393,7 +394,7 @@ def get_environment_variable(argument):
|
||||
|
||||
def run(args):
|
||||
host = args.orm_base_url if args.orm_base_url else config.orm_base_url
|
||||
port = args.port if args.port else 7080
|
||||
port = args.port if args.port else base_config.cms['port']
|
||||
data = args.datafile.read() if 'datafile' in args else '{}'
|
||||
timeout = args.timeout if args.timeout else 10
|
||||
|
||||
@ -428,7 +429,7 @@ def run(args):
|
||||
|
||||
try:
|
||||
resp = rest_cmd(url, timeout=timeout, data=data, headers=headers,
|
||||
verify=config.verify)
|
||||
verify=False)
|
||||
except Exception as e:
|
||||
print e
|
||||
exit(1)
|
||||
|
0
orm/orm_client/ormcli/config.py
Normal file → Executable file
0
orm/orm_client/ormcli/config.py
Normal file → Executable file
@ -2,6 +2,7 @@
|
||||
import argparse
|
||||
import cli_common
|
||||
import config
|
||||
import orm.base_config as base_config
|
||||
import os
|
||||
import requests
|
||||
|
||||
@ -304,7 +305,7 @@ def get_token(timeout, args, host):
|
||||
print message
|
||||
raise cli_common.MissingArgumentError(message)
|
||||
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:8080'.format(host),
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:{}'.format(host, base_config.rms['port']),
|
||||
auth_region)
|
||||
if keystone_ep is None:
|
||||
raise ConnectionError(
|
||||
@ -340,7 +341,7 @@ def get_environment_variable(argument):
|
||||
|
||||
def run(args):
|
||||
host = args.orm_base_url if args.orm_base_url else config.orm_base_url
|
||||
port = args.port if args.port else 8082
|
||||
port = args.port if args.port else base_config.fms['port']
|
||||
data = args.datafile.read() if 'datafile' in args else '{}'
|
||||
timeout = args.timeout if args.timeout else 10
|
||||
|
||||
@ -374,7 +375,7 @@ def run(args):
|
||||
timeout, data, headers, rest_cmd.__name__, url))
|
||||
try:
|
||||
resp = rest_cmd(url, timeout=timeout, data=data, headers=headers,
|
||||
verify=config.verify)
|
||||
verify=False)
|
||||
except Exception as e:
|
||||
print e
|
||||
exit(1)
|
||||
|
@ -2,6 +2,7 @@
|
||||
import argparse
|
||||
import cli_common
|
||||
import config
|
||||
import orm.base_config as base_config
|
||||
import os
|
||||
import requests
|
||||
|
||||
@ -204,7 +205,7 @@ def get_token(timeout, args, host):
|
||||
print message
|
||||
raise cli_common.MissingArgumentError(message)
|
||||
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:8080'.format(host),
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:{}'.format(host, base_config.rms['port']),
|
||||
auth_region)
|
||||
if keystone_ep is None:
|
||||
raise ConnectionError(
|
||||
@ -307,7 +308,7 @@ def get_environment_variable(argument):
|
||||
|
||||
def run(args):
|
||||
host = args.orm_base_url if args.orm_base_url else config.orm_base_url
|
||||
port = args.port if args.port else 8084
|
||||
port = args.port if args.port else base_config.ims['port']
|
||||
timeout = args.timeout if args.timeout else 10
|
||||
|
||||
rest_cmd, cmd_url, data = cmd_details(args)
|
||||
@ -342,7 +343,7 @@ def run(args):
|
||||
url))
|
||||
try:
|
||||
resp = rest_cmd(url, timeout=timeout, data=data, headers=headers,
|
||||
verify=config.verify)
|
||||
verify=False)
|
||||
except Exception as e:
|
||||
print e
|
||||
exit(1)
|
||||
|
0
orm/orm_client/ormcli/orm
Normal file → Executable file
0
orm/orm_client/ormcli/orm
Normal file → Executable file
@ -2,6 +2,7 @@
|
||||
import argparse
|
||||
import cli_common
|
||||
import config
|
||||
import orm.base_config as base_config
|
||||
import os
|
||||
import requests
|
||||
|
||||
@ -202,7 +203,7 @@ def get_token(timeout, args, host):
|
||||
print message
|
||||
raise cli_common.MissingArgumentError(message)
|
||||
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:8080'.format(host),
|
||||
keystone_ep = cli_common.get_keystone_ep('{}:{}'.format(host, base_config.rms['port']),
|
||||
auth_region)
|
||||
if keystone_ep is None:
|
||||
raise ConnectionError(
|
||||
@ -314,7 +315,7 @@ def get_environment_variable(argument):
|
||||
def run(args):
|
||||
url_path = get_path(args)
|
||||
host = args.orm_base_url if args.orm_base_url else config.orm_base_url
|
||||
port = args.port if args.port else 8080
|
||||
port = args.port if args.port else base_config.rms['port']
|
||||
data = args.datafile.read() if 'datafile' in args else '{}'
|
||||
timeout = args.timeout if args.timeout else 10
|
||||
rest_cmd, cmd_url = cmd_details(args)
|
||||
@ -360,7 +361,7 @@ def run(args):
|
||||
url))
|
||||
try:
|
||||
resp = rest_cmd(url, data=data, timeout=timeout, headers=headers,
|
||||
verify=config.verify)
|
||||
verify=False)
|
||||
except Exception as e:
|
||||
print e
|
||||
exit(1)
|
||||
|
@ -8,15 +8,15 @@ server = {
|
||||
|
||||
# DB configurations
|
||||
database = {
|
||||
'url': 'mysql://root:stack@127.0.0.1/orm_audit?charset=utf8',
|
||||
'url': config.db_url + 'orm_audit?charset=utf8',
|
||||
# 'url': 'mysql://root:root@127.0.0.1/orm_audit?charset=utf8',
|
||||
'echo_statements': True
|
||||
}
|
||||
|
||||
# Pecan Application Configurations
|
||||
app = {
|
||||
'root': 'audit_server.controllers.root.RootController',
|
||||
'modules': ['audit_server'],
|
||||
'root': 'orm.services.audit_trail_manager.audit_server.controllers.root.RootController',
|
||||
'modules': ['orm.services.audit_trail_manager.audit_server'],
|
||||
'static_root': '%(confdir)s/public',
|
||||
'template_path': '%(confdir)s/audit_server/templates',
|
||||
'debug': True,
|
||||
@ -63,7 +63,7 @@ logging = {
|
||||
}
|
||||
}
|
||||
|
||||
verify = False
|
||||
verify = config.ssl_verify
|
||||
|
||||
# Custom Configurations must be in Python dictionary format::
|
||||
#
|
||||
|
@ -11,14 +11,14 @@ server = {
|
||||
'port': config.cms['port'],
|
||||
'host': config.orm_host,
|
||||
'name': 'cms',
|
||||
'host_ip': '0.0.0.0'
|
||||
'host_ip': config.orm_host
|
||||
}
|
||||
|
||||
# Pecan Application Configurations
|
||||
|
||||
app = {
|
||||
'root': 'cms_rest.controllers.root.RootController',
|
||||
'modules': ['cms_rest'],
|
||||
'root': 'orm.services.customer_manager.cms_rest.controllers.root.RootController',
|
||||
'modules': ['orm.services.customer_manager.cms_rest'],
|
||||
'static_root': '%(confdir)s/public',
|
||||
'template_path': '%(confdir)s/cms_rest/templates',
|
||||
'debug': True,
|
||||
@ -80,45 +80,45 @@ quotas_default_values = {
|
||||
}
|
||||
|
||||
database = {
|
||||
'connection_string': 'mysql://root:stack@localhost:3306/orm_cms_db'
|
||||
'connection_string': config.db_url + 'orm_cms_db'
|
||||
}
|
||||
|
||||
api = {
|
||||
'uuid_server': {
|
||||
'base': 'http://127.0.0.1:8090/',
|
||||
'base': config.uuid['base_url'],
|
||||
'uuids': 'v1/uuids'
|
||||
},
|
||||
'rds_server': {
|
||||
'base': 'http://127.0.0.1:8777/',
|
||||
'base': config.rds['base_url'],
|
||||
'resources': 'v1/rds/resources',
|
||||
'status': 'v1/rds/status/resource/'
|
||||
},
|
||||
'rms_server': {
|
||||
'base': 'http://127.0.0.1:8080/',
|
||||
'base': config.rms['base_url'],
|
||||
'regions': 'v2/orm/regions',
|
||||
'groups': 'v2/orm/groups',
|
||||
'cache_seconds': 30
|
||||
},
|
||||
'audit_server': {
|
||||
'base': 'http://127.0.0.1:8776/',
|
||||
'base': config.audit_server['base_url'],
|
||||
'trans': 'v1/audit/transaction'
|
||||
}
|
||||
}
|
||||
|
||||
verify = False
|
||||
verify = config.ssl_verify
|
||||
|
||||
authentication = {
|
||||
"enabled": True,
|
||||
"mech_id": "admin",
|
||||
"mech_pass": "stack",
|
||||
"rms_url": "http://127.0.0.1:8080",
|
||||
"tenant_name": "admin",
|
||||
"token_role": "admin",
|
||||
"enabled": config.token_auth_enabled,
|
||||
"mech_id": config.token_auth_user,
|
||||
"mech_pass": config.token_auth_pass,
|
||||
"rms_url": config.rms['base_url'],
|
||||
"tenant_name": config.token_auth_tenant,
|
||||
"token_role": config.token_auth_user_role,
|
||||
# The Keystone collection under which the role was granted.
|
||||
# The key can be either "tenant" (for Keystone v2.0) or "domain"
|
||||
# (for Keystone v3) and the value is the tenant/domain name.
|
||||
"role_location": {"tenant": "admin"},
|
||||
# The Keystone version currently in use. Can be either "2.0" or "3".
|
||||
"keystone_version": "2.0",
|
||||
"policy_file": "/opt/stack/ranger/orm/services/customer_manager/cms_rest/etc/policy.json"
|
||||
"policy_file": config.cms['policy_file']
|
||||
}
|
||||
|
@ -17,8 +17,8 @@ cache_seconds = 0
|
||||
|
||||
# Pecan Application Configurations
|
||||
app = {
|
||||
'root': 'fms_rest.controllers.root.RootController',
|
||||
'modules': ['fms_rest'],
|
||||
'root': 'orm.services.flavor_manager.fms_rest.controllers.root.RootController',
|
||||
'modules': ['orm.services.flavor_manager.fms_rest'],
|
||||
'static_root': '%(confdir)s/public',
|
||||
'template_path': '%(confdir)s/fms_rest/templates',
|
||||
'debug': True,
|
||||
@ -69,9 +69,9 @@ logging = {
|
||||
}
|
||||
|
||||
database = {
|
||||
'host': 'localhost',
|
||||
'username': 'root',
|
||||
'password': 'stack',
|
||||
'host': config.db_host,
|
||||
'username': config.db_user,
|
||||
'password': config.db_pass,
|
||||
'db_name': 'orm_fms_db',
|
||||
|
||||
}
|
||||
@ -124,39 +124,37 @@ application_root = 'http://localhost:{0}'.format(server['port'])
|
||||
|
||||
api = {
|
||||
'uuid_server': {
|
||||
'base': 'http://127.0.0.1:8090/',
|
||||
'base': config.uuid['base_url'],
|
||||
'uuids': 'v1/uuids'
|
||||
},
|
||||
'rds_server': {
|
||||
'base': 'http://127.0.0.1:8777/',
|
||||
# 'base': 'http://127.0.0.1:8777/',
|
||||
'base': config.rds['base_url'],
|
||||
'resources': 'v1/rds/resources',
|
||||
'status': 'v1/rds/status/resource/'
|
||||
},
|
||||
'rms_server': {
|
||||
'base': 'http://127.0.0.1:8080/',
|
||||
'base': config.rms['base_url'],
|
||||
'groups': 'v2/orm/groups',
|
||||
'regions': 'v2/orm/regions',
|
||||
'cache_seconds': 60
|
||||
},
|
||||
'audit_server': {
|
||||
'base': 'http://127.0.0.1:8776/',
|
||||
'base': config.audit_server['base_url'],
|
||||
'trans': 'v1/audit/transaction'
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
verify = False
|
||||
verify = config.ssl_verify
|
||||
|
||||
authentication = {
|
||||
"enabled": False,
|
||||
"mech_id": "admin",
|
||||
"mech_pass": "stack",
|
||||
"rms_url": "http://127.0.0.1:8080",
|
||||
# "rms_url": "http://127.0.0.1:8080",
|
||||
"tenant_name": "admin",
|
||||
"token_role": "admin",
|
||||
"enabled": config.token_auth_enabled,
|
||||
"mech_id": config.token_auth_user,
|
||||
"mech_pass": config.token_auth_pass,
|
||||
"rms_url": config.rms['base_url'],
|
||||
"tenant_name": config.token_auth_tenant,
|
||||
"token_role": config.token_auth_user_role,
|
||||
# The Keystone version currently in use. Can be either "2.0" or "3"
|
||||
"keystone_version": "2.0",
|
||||
"policy_file": "fms_rest/etc/policy.json",
|
||||
"policy_file": config.fms['policy_file'],
|
||||
}
|
||||
|
@ -6,8 +6,8 @@ server = {
|
||||
}
|
||||
# Pecan Application Configurations
|
||||
app = {
|
||||
'root': 'uuidgen.controllers.root.RootController',
|
||||
'modules': ['uuidgen'],
|
||||
'root': 'orm.services.id_generator.uuidgen.controllers.root.RootController',
|
||||
'modules': ['orm.services.id_generator.uuidgen'],
|
||||
'static_root': '%(confdir)s/public',
|
||||
'template_path': '%(confdir)s/uuidgen/templates',
|
||||
'debug': True,
|
||||
@ -56,10 +56,10 @@ logging = {
|
||||
}
|
||||
}
|
||||
|
||||
verify = False
|
||||
verify = config.ssl_verify
|
||||
|
||||
database = {
|
||||
'connection_string': 'mysql://root:stack@localhost:3306/orm'
|
||||
'connection_string': config.db_url + 'orm'
|
||||
}
|
||||
# Custom Configurations must be in Python dictionary format::
|
||||
#
|
||||
|
@ -15,8 +15,8 @@ server = {
|
||||
|
||||
# Pecan Application Configurations
|
||||
app = {
|
||||
'root': 'ims.controllers.root.RootController',
|
||||
'modules': ['ims'],
|
||||
'root': 'orm.services.image_manager.ims.controllers.root.RootController',
|
||||
'modules': ['orm.services.image_manager.ims'],
|
||||
'static_root': '%(confdir)s/public',
|
||||
'template_path': '%(confdir)s/ims/templates',
|
||||
'debug': True,
|
||||
@ -70,52 +70,51 @@ logging = {
|
||||
}
|
||||
|
||||
database = {
|
||||
'host': 'localhost',
|
||||
'username': 'root',
|
||||
'password': 'stack',
|
||||
'host': config.db_host,
|
||||
'username': config.db_user,
|
||||
'password': config.db_pass,
|
||||
'db_name': 'orm_ims_db',
|
||||
|
||||
}
|
||||
|
||||
verify = False
|
||||
|
||||
database['connection_string'] = 'mysql://{0}:{1}@{2}:3306/{3}'.format(database['username'],
|
||||
database['password'],
|
||||
database['host'],
|
||||
database['db_name'])
|
||||
|
||||
application_root = 'http://localhost:{0}'.format(server['port'])
|
||||
application_root = config.ims['base_url']
|
||||
|
||||
api = {
|
||||
'uuid_server': {
|
||||
'base': 'http://127.0.0.1:8090/',
|
||||
'base': config.uuid['base_url'],
|
||||
'uuids': 'v1/uuids'
|
||||
},
|
||||
'rds_server': {
|
||||
'base': 'http://127.0.0.1:8777/',
|
||||
'base': config.rds['base_url'],
|
||||
'resources': 'v1/rds/resources',
|
||||
'status': 'v1/rds/status/resource/'
|
||||
},
|
||||
'rms_server': {
|
||||
'base': 'http://127.0.0.1:8080/',
|
||||
'base': config.rms['base_url'],
|
||||
'groups': 'v2/orm/groups',
|
||||
'regions': 'v2/orm/regions',
|
||||
'cache_seconds': 60
|
||||
},
|
||||
'audit_server': {
|
||||
'base': 'http://127.0.0.1:8776/',
|
||||
'base': config.audit_server['base_url'],
|
||||
'trans': 'v1/audit/transaction'
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
verify = config.ssl_verify
|
||||
|
||||
authentication = {
|
||||
"enabled": True,
|
||||
"mech_id": "admin",
|
||||
"mech_pass": "stack",
|
||||
"rms_url": "http://127.0.0.1:8080",
|
||||
"tenant_name": "admin",
|
||||
"token_role": "admin",
|
||||
"enabled": config.token_auth_enabled,
|
||||
"mech_id": config.token_auth_user,
|
||||
"mech_pass": config.token_auth_pass,
|
||||
"rms_url": config.rms['base_url'],
|
||||
"tenant_name": config.token_auth_tenant,
|
||||
"token_role": config.token_auth_user_role,
|
||||
"keystone_version": "2.0",
|
||||
"policy_file": "ims/etc/policy.json"
|
||||
"policy_file": config.ims['policy_file']
|
||||
}
|
||||
|
@ -15,8 +15,8 @@ server = {
|
||||
|
||||
# Pecan Application Configurations
|
||||
app = {
|
||||
'root': 'rms.controllers.root.RootController',
|
||||
'modules': ['rms'],
|
||||
'root': 'orm.services.region_manager.rms.controllers.root.RootController',
|
||||
'modules': ['orm.services.region_manager.rms'],
|
||||
'static_root': '%(confdir)s/public',
|
||||
'template_path': '%(confdir)s/rms/templates',
|
||||
'debug': True,
|
||||
@ -86,34 +86,34 @@ region_options = {
|
||||
|
||||
# DB configurations
|
||||
database = {
|
||||
'url': 'mysql://root:stack@127.0.0.1/orm_rms_db?charset=utf8',
|
||||
'url': config.db_url + 'orm_rms_db?charset=utf8',
|
||||
'max_retries': 3,
|
||||
'retries_interval': 10
|
||||
}
|
||||
|
||||
endpoints = {
|
||||
'lcp': 'http://127.0.0.1:8082/lcp'
|
||||
'lcp': config.rms['base_url'] + 'lcp'
|
||||
}
|
||||
|
||||
api = {
|
||||
'uuid_server': {
|
||||
'base': 'http://127.0.0.1:8090/',
|
||||
'base': config.uuid['base_url'],
|
||||
'uuids': 'v1/uuids'
|
||||
},
|
||||
'audit_server': {
|
||||
'base': 'http://127.0.0.1:8776/',
|
||||
'base': config.audit_server['base_url'],
|
||||
'trans': 'v1/audit/transaction'
|
||||
}
|
||||
}
|
||||
|
||||
verify = False
|
||||
verify = config.ssl_verify
|
||||
|
||||
authentication = {
|
||||
"enabled": True,
|
||||
"mech_id": "admin",
|
||||
"mech_pass": "stack",
|
||||
"tenant_name": "admin",
|
||||
"enabled": config.token_auth_enabled,
|
||||
"mech_id": config.token_auth_user,
|
||||
"mech_pass": config.token_auth_pass,
|
||||
"tenant_name": config.token_auth_tenant,
|
||||
# The Keystone version currently in use. Can be either "2.0" or "3"
|
||||
"keystone_version": "2.0",
|
||||
"policy_file": "/stack/orm/services/region_manager/rms/etc/policy.json"
|
||||
"policy_file": config.rms['policy_file']
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
import orm.base_config as config
|
||||
# Pecan Application configurations
|
||||
app = {
|
||||
'root': 'rds.controllers.root.RootController',
|
||||
'modules': ['rds'],
|
||||
'root': 'orm.services.resource_distributor.rds.controllers.root.RootController',
|
||||
'modules': ['orm.services.resource_distributor.rds'],
|
||||
'service_name': 'RDS'
|
||||
}
|
||||
|
||||
@ -13,7 +13,7 @@ server = {
|
||||
|
||||
# DB configurations
|
||||
database = {
|
||||
'url': 'mysql://root:stack@127.0.0.1/orm_rds?charset=utf8'
|
||||
'url': config.db_url + 'orm_rds?charset=utf8'
|
||||
}
|
||||
|
||||
sot = {
|
||||
@ -23,35 +23,35 @@ sot = {
|
||||
git = {
|
||||
# possible values : 'native', 'gittle'
|
||||
'type': 'native',
|
||||
'local_repository_path': '/opt/app/orm/ORM',
|
||||
'local_repository_path': config.rds['repo_local_location'],
|
||||
'file_name_format': 's_{}.yml',
|
||||
'relative_path_format': '/{}/hot/{}/{}',
|
||||
'commit_message_format': 'File was added to repository: {}',
|
||||
'commit_user': 'orm_rds',
|
||||
'commit_email': 'orm_rds@att.com',
|
||||
'git_server_url': 'orm_rds@127.0.0.1:~/SoT/ORM.git',
|
||||
'commit_user': config.rds['repo_user'],
|
||||
'commit_email': config.rds['repo_email'],
|
||||
'git_server_url': config.rds['repo_remote_location'],
|
||||
'git_cmd_timeout': 45
|
||||
}
|
||||
|
||||
audit = {
|
||||
'audit_server_url': 'http://127.0.0.1:8776/v1/audit/transaction',
|
||||
'audit_server_url': config.audit_server['base_url'] + 'v1/audit/transaction',
|
||||
'num_of_send_retries': 3,
|
||||
'time_wait_between_retries': 1
|
||||
}
|
||||
|
||||
ims = {
|
||||
'base_url': 'http://127.0.0.1:8084/',
|
||||
'base_url': config.ims['base_url'],
|
||||
'metadata_path': 'v1/orm/images/{0}/regions/{1}/metadata'
|
||||
}
|
||||
|
||||
rms = {
|
||||
'base_url': 'http://127.0.0.1:8080/',
|
||||
'base_url': config.rms['base_url'],
|
||||
'all_regions_path': 'v2/orm/regions'
|
||||
}
|
||||
|
||||
ordupdate = {
|
||||
'discovery_url': 'http://127.0.0.1',
|
||||
'discovery_port': 8080,
|
||||
'discovery_port': config.rms['port'],
|
||||
'template_type': 'hot',
|
||||
# This flag should be false only in case the ord does not support https.
|
||||
'https_enabled': True,
|
||||
@ -59,9 +59,7 @@ ordupdate = {
|
||||
'cert_path': '../resources/ord.crt'
|
||||
}
|
||||
|
||||
verify = False
|
||||
|
||||
UUID_URL = 'http://127.0.0.1:8090/v1/uuids'
|
||||
UUID_URL = config.uuid['base_url'] + 'uuids'
|
||||
|
||||
# yaml configurations
|
||||
yaml_configs = {
|
||||
@ -167,11 +165,14 @@ logging = {
|
||||
}
|
||||
|
||||
|
||||
verify = config.ssl_verify
|
||||
|
||||
authentication = {
|
||||
"enabled": True,
|
||||
"mech_id": "admin",
|
||||
"mech_pass": "stack",
|
||||
"tenant_name": "admin",
|
||||
"enabled": config.token_auth_enabled,
|
||||
"mech_id": config.token_auth_user,
|
||||
"mech_pass": config.token_auth_pass,
|
||||
"tenant_name": config.token_auth_tenant,
|
||||
"token_role": config.token_auth_user_role,
|
||||
# The Keystone version currently in use. Can be either "2.0" or "3"
|
||||
"keystone_version": "2.0"
|
||||
}
|
||||
|
3
tools/setenv.sh
Executable file
3
tools/setenv.sh
Executable file
@ -0,0 +1,3 @@
|
||||
export RANGER_BASE='/opt/stack/ranger'
|
||||
export HTTP_PROXY=''
|
||||
export MYSQL_PASSWORD=stack
|
@ -1,4 +1,6 @@
|
||||
root_dir=/opt/stack/upstream_ranger/ranger
|
||||
source ./setenv.sh
|
||||
|
||||
root_dir=$RANGER_BASE
|
||||
|
||||
audit_dir=$root_dir/orm/services/audit_trail_manager
|
||||
customer_dir=$root_dir/orm/services/customer_manager
|
||||
@ -7,19 +9,6 @@ id_dir=$root_dir/orm/services/id_generator
|
||||
image_dir=$root_dir/orm/services/image_manager
|
||||
region_dir=$root_dir/orm/services/region_manager
|
||||
resource_dir=$root_dir/orm/services/resource_distributor
|
||||
cd $root_dir
|
||||
sudo pip install -r requirements.txt --proxy $HTTP_PROXY
|
||||
cd $root_dir/orm/services
|
||||
list_dirs=`ls -d */ | xargs`
|
||||
for dir in $list_dirs; do
|
||||
cd $dir
|
||||
echo "-------------"
|
||||
echo `pwd`
|
||||
echo "-------------"
|
||||
sudo python setup.py develop 2>&1 | tee ~/${dir}.log
|
||||
cd $root_dir
|
||||
done
|
||||
mkdir $root_dir/logs
|
||||
|
||||
sudo ln -s $audit_dir/audit_server.conf /etc/apache2/sites-enabled/audit_server.conf
|
||||
sudo ln -s $customer_dir/cms_rest.conf /etc/apache2/sites-enabled/cms_rest.conf
|
||||
@ -28,3 +17,4 @@ sudo ln -s $id_dir/uuidgen.conf /etc/apache2/sites-enabled/uuidgen.conf
|
||||
sudo ln -s $image_dir/ims.conf /etc/apache2/sites-enabled/ims.conf
|
||||
sudo ln -s $region_dir/rms.conf /etc/apache2/sites-enabled/rms.conf
|
||||
sudo ln -s $resource_dir/rds.conf /etc/apache2/sites-enabled/rds.conf
|
||||
|
11
tools/stack_orm.sh
Executable file
11
tools/stack_orm.sh
Executable file
@ -0,0 +1,11 @@
|
||||
|
||||
source ./setenv.sh
|
||||
|
||||
root_dir=$RANGER_BASE
|
||||
|
||||
cd $root_dir
|
||||
mkdir $root_dir/logs
|
||||
sudo pip install -r requirements.txt --proxy $HTTP_PROXY
|
||||
echo "-------------"
|
||||
sudo python setup.py develop 2>&1 | tee $root_dir/tools/install.log
|
||||
|
Loading…
x
Reference in New Issue
Block a user