Show More
@@ -68,7 +68,7 b' def main(ini_path, mode, user, user_id, ' | |||
|
68 | 68 | 'of this script.') |
|
69 | 69 | connection_info = os.environ.get('SSH_CONNECTION', '') |
|
70 | 70 | |
|
71 | with bootstrap(ini_path) as env: | |
|
71 | with bootstrap(ini_path, env={'RC_CMD_SSH_WRAPPER': '1'}) as env: | |
|
72 | 72 | try: |
|
73 | 73 | ssh_wrapper = SshWrapper( |
|
74 | 74 | command, connection_info, mode, |
@@ -36,7 +36,9 b' def get_app_config(ini_path):' | |||
|
36 | 36 | return appconfig('config:{}'.format(ini_path), relative_to=os.getcwd()) |
|
37 | 37 | |
|
38 | 38 | |
|
39 | def bootstrap(config_uri, request=None, options=None): | |
|
39 | def bootstrap(config_uri, request=None, options=None, env=None): | |
|
40 | if env: | |
|
41 | os.environ.update(env) | |
|
40 | 42 | |
|
41 | 43 | config = get_config(config_uri) |
|
42 | 44 | base_url = 'http://rhodecode.local' |
@@ -95,7 +95,7 b' def command(ini_path, force_yes, user, e' | |||
|
95 | 95 | dbmanage.populate_default_permissions() |
|
96 | 96 | Session().commit() |
|
97 | 97 | |
|
98 | with bootstrap(ini_path) as env: | |
|
98 | with bootstrap(ini_path, env={'RC_CMD_SETUP_RC': '1'}) as env: | |
|
99 | 99 | msg = 'Successfully initialized database, schema and default data.' |
|
100 | 100 | print() |
|
101 | 101 | print('*' * len(msg)) |
@@ -40,7 +40,7 b' def main(ini_path, force_yes):' | |||
|
40 | 40 | def command(ini_path, force_yes): |
|
41 | 41 | pyramid.paster.setup_logging(ini_path) |
|
42 | 42 | |
|
43 | with bootstrap(ini_path) as env: | |
|
43 | with bootstrap(ini_path, env={'RC_CMD_UPGRADE_DB': '1'}) as env: | |
|
44 | 44 | config = env['registry'].settings |
|
45 | 45 | db_uri = config['sqlalchemy.db1.url'] |
|
46 | 46 | options = {} |
General Comments 0
You need to be logged in to leave comments.
Login now