Config Package (autotransform.config)
Provides configuration to AutoTransform. By default this configuration is pulled from config files. The configuration fetcher used can be overridden using the AUTO_TRANSFORM_CONFIG environment variable. This can support different methods of configuration, such as environment variables or a custom approach where the environment variable is set to “{‘class_name’: <A ConfigFetcher Class>, ‘module’: <The module where the class is located>}”.
- autotransform.config.get_config() Config
Gets the Config for AutoTransform.
- Returns
The cached Config.
- Return type
- autotransform.config.get_cwd_config_dir() str
Gets the directory where an AutoTransform config file would be located relative to the current working directory. The environment variable AUTO_TRANSFORM_CWD_CONFIG_PATH can be used to set the relative path to the config.json file for CWD configs.
- Returns
The directory of the cwd config file.
- Return type
str
- autotransform.config.get_repo_config_dir() Optional[str]
Gets the directory where a repo-specific AutoTransform config file would be located. None if git fails. The environment variable AUTO_TRANSFORM_REPO_CONFIG_PATH can be used to set the relative path to the config.json file for repo configs.
- Returns
The directory of the repo config file. None if git fails.
- Return type
Optional[str]
- autotransform.config.get_repo_config_relative_path() str
Gets the relative path used for the repo config directory.
- Returns
The relative path to the config.
- Return type
str
- Config (autotransform.config.config)
Config
Config.component_directory
Config.github_token
Config.github_base_url
Config.jenkins_user
Config.jenkins_token
Config.jenkins_base_url
Config.local_runner
Config.remote_runner
Config.component_directory
Config.from_console()
Config.from_data()
Config.from_json()
Config.get_component_directory_from_console()
Config.get_github_base_url_from_console()
Config.get_github_token_from_console()
Config.get_jenkins_base_url_from_console()
Config.get_jenkins_token_from_console()
Config.get_jenkins_user_from_console()
Config.get_local_runner_from_console()
Config.get_remote_runner_from_console()
Config.github_base_url
Config.github_token
Config.jenkins_base_url
Config.jenkins_token
Config.jenkins_user
Config.local_runner
Config.merge()
Config.read()
Config.remote_runner
Config.write()
- ConfigFetcher (autotransform.config.fetcher)
- DefaultConfigFetcher (autotransform.config.default)
- EnvironmentConfigFetcher (autotransform.config.environment)