def main(): parser = ArgumentParser(description='Run all migration scripts.') parser.add_argument('migrations_dir', help='Directory with the migrations') parser.add_argument('config', help='Service config file') parser.add_argument('secrets', help='Service database admin secrets') args = parser.parse_args() run_all_scripts(args.migrations_dir, args.config, args.secrets)
def setup_database(): scripts_dir = os.path.join( os.path.dirname(__file__), 'database', 'migrations', ) config_file_name = utils.get_config_test_filename() secrets_file_name = utils.get_admin_secrets_filename() utils.run_all_scripts(scripts_dir, config_file_name, secrets_file_name)
def setup_database(): scripts_dir = path.join( path.dirname(__file__), "..", "database", "migrations", ) config_file_name = utils.get_config_test_filename() secrets_file_name = utils.get_admin_secrets_filename() utils.run_all_scripts(scripts_dir, config_file_name, secrets_file_name)