Warning

This document is for an old release of Galaxy. You can alternatively view this page in the latest release if it exists or view the top of the latest release's documentation.

galaxy.config package

Universe configuration builder.

galaxy.config.LOGGING_CONFIG_DEFAULT = {'disable_existing_loggers': False, 'filters': {'stack': {'()': 'galaxy.web_stack.application_stack_log_filter'}}, 'formatters': {'stack': {'()': 'galaxy.web_stack.application_stack_log_formatter'}}, 'handlers': {'console': {'class': 'logging.StreamHandler', 'filters': ['stack'], 'formatter': 'stack', 'level': 'DEBUG', 'stream': 'ext://sys.stderr'}}, 'loggers': {'amqp': {'level': 'INFO', 'qualname': 'amqp'}, 'botocore': {'level': 'INFO', 'qualname': 'botocore'}, 'paste.httpserver.ThreadPool': {'level': 'WARN', 'qualname': 'paste.httpserver.ThreadPool'}, 'routes.middleware': {'level': 'WARN', 'qualname': 'routes.middleware'}, 'sqlalchemy_json.track': {'level': 'WARN', 'qualname': 'sqlalchemy_json.track'}, 'urllib3.connectionpool': {'level': 'WARN', 'qualname': 'urllib3.connectionpool'}}, 'root': {'handlers': ['console'], 'level': 'DEBUG'}, 'version': 1}

Default value for logging configuration, passed to logging.config.dictConfig()

galaxy.config.find_root(kwargs)[source]
class galaxy.config.BaseAppConfiguration(**kwargs)[source]

Bases: object

renamed_options: Optional[Dict[str, str]] = None
deprecated_dirs: Dict[str, str] = {}
paths_to_check_against_root: Set[str] = {}
add_sample_file_to_defaults: Set[str] = {}
listify_options: Set[str] = {}
__init__(**kwargs)[source]

Initialize self. See help(type(self)) for accurate signature.

is_set(key)[source]

Check if a configuration option has been explicitly set.

resolve_path(path)[source]

Resolve a path relative to Galaxy’s root.

class galaxy.config.CommonConfigurationMixin[source]

Bases: object

Shared configuration settings code for Galaxy and ToolShed.

property admin_users
is_admin_user(user)[source]

Determine if the provided user is listed in admin_users.

property sentry_dsn_public

Sentry URL with private key removed for use in client side scripts, sentry server will need to be configured to accept events

get_bool(key, default)[source]
get(key, default=None)[source]
class galaxy.config.GalaxyAppConfiguration(**kwargs)[source]

Bases: galaxy.config.BaseAppConfiguration, galaxy.config.CommonConfigurationMixin

deprecated_options = ('database_file', 'track_jobs_in_database', 'blacklist_file', 'whitelist_file', 'sanitize_whitelist_file', 'user_library_import_symlink_whitelist', 'fetch_url_whitelist', 'containers_resolvers_config_file')
renamed_options: Optional[Dict[str, str]] = {'blacklist_file': 'email_domain_blocklist_file', 'containers_resolvers_config_file': 'container_resolvers_config_file', 'fetch_url_whitelist': 'fetch_url_allowlist', 'sanitize_whitelist_file': 'sanitize_allowlist_file', 'user_library_import_symlink_whitelist': 'user_library_import_symlink_allowlist', 'whitelist_file': 'email_domain_allowlist_file'}
default_config_file_name = 'galaxy.yml'
deprecated_dirs: Dict[str, str] = {'config_dir': 'config', 'data_dir': 'database'}
paths_to_check_against_root: Set[str] = {'auth_config_file', 'build_sites_config_file', 'containers_config_file', 'data_manager_config_file', 'datatypes_config_file', 'dependency_resolvers_config_file', 'error_report_file', 'file_path', 'job_config_file', 'job_metrics_config_file', 'job_resource_params_file', 'local_conda_mapping_file', 'markdown_export_css', 'markdown_export_css_invocation_reports', 'markdown_export_css_pages', 'migrated_tools_config', 'modules_mapping_files', 'object_store_config_file', 'oidc_backends_config_file', 'oidc_config_file', 'shed_data_manager_config_file', 'shed_tool_config_file', 'shed_tool_data_table_config', 'tool_config_file', 'tool_data_table_config_path', 'tool_destinations_config_file', 'tool_sheds_config_file', 'user_preferences_extra_conf_path', 'workflow_resource_params_file', 'workflow_schedulers_config_file'}
add_sample_file_to_defaults: Set[str] = {'build_sites_config_file', 'datatypes_config_file', 'job_metrics_config_file', 'tool_config_file', 'tool_data_table_config_path'}
listify_options: Set[str] = {'tool_config_file', 'tool_data_table_config_path'}
__init__(**kwargs)[source]

Initialize self. See help(type(self)) for accurate signature.

config_value_for_host(config_option, host)[source]
reload_sanitize_allowlist(explicit=True)[source]
ensure_tempdir()[source]
check()[source]
galaxy.config.Configuration

alias of galaxy.config.GalaxyAppConfiguration

galaxy.config.reload_config_options(current_config)[source]

Reload modified reloadable config options.

galaxy.config.get_database_engine_options(kwargs, model_prefix='')[source]

Allow options for the SQLAlchemy database engine to be passed by using the prefix “database_engine_option”.

galaxy.config.get_database_url(config)[source]
galaxy.config.init_models_from_config(config, map_install_models=False, object_store=None, trace_logger=None)[source]
galaxy.config.configure_logging(config)[source]

Allow some basic logging configuration to be read from ini file.

This should be able to consume either a galaxy.config.Configuration object or a simple dictionary of configuration variables.

class galaxy.config.ConfiguresGalaxyMixin[source]

Bases: object

Shared code for configuring Galaxy-like app objects.

wait_for_toolbox_reload(old_toolbox)[source]
property tool_dependency_dir

Submodules

galaxy.config.config_manage module

class galaxy.config.config_manage.App(config_paths, default_port, expected_app_factories, destination, schema_path, uwsgi_module)[source]

Bases: tuple

property config_paths

Alias for field number 0

property default_port

Alias for field number 1

property expected_app_factories

Alias for field number 2

property destination

Alias for field number 3

property schema_path

Alias for field number 4

property uwsgi_module

Alias for field number 5

property app_name
property sample_destination
property schema
class galaxy.config.config_manage.OptionValue(name, value, option)[source]

Bases: tuple

property name

Alias for field number 0

property value

Alias for field number 1

property option

Alias for field number 2

galaxy.config.config_manage.main(argv=None)[source]

Entry point for conversion process.

class galaxy.config.config_manage.PrefixFilter(name, prefix)[source]

Bases: object

__init__(name, prefix)[source]

Initialize self. See help(type(self)) for accurate signature.

class galaxy.config.config_manage.GzipFilter(name)[source]

Bases: object

__init__(name)[source]

Initialize self. See help(type(self)) for accurate signature.

galaxy.config.schema module

class galaxy.config.schema.Schema(mapping)[source]

Bases: object

__init__(mapping)[source]

Initialize self. See help(type(self)) for accurate signature.

get_app_option(name)[source]
class galaxy.config.schema.AppSchema(schema_path, app_name)[source]

Bases: galaxy.config.schema.Schema

__init__(schema_path, app_name)[source]

Initialize self. See help(type(self)) for accurate signature.

property defaults
property paths_to_resolve
property reloadable_options
property per_host_options
validate_path_resolution_graph()[source]

This method is for tests only: we SHOULD validate the schema’s path resolution graph as part of automated testing; but we should NOT validate it at runtime.

galaxy.config.script module

galaxy.config.script.main(argv=None)[source]