Skip to main content
Version: Next

@backstage/config-loader

Home > @backstage/config-loader

Config loading functionality used by Backstage backend, and CLI

Classes

ClassDescription
ConfigSourcesA collection of utilities for working with and creating ConfigSources.
EnvConfigSourceA config source that reads configuration from the environment.
FileConfigSourceA config source that loads configuration from a local file.
MutableConfigSourceA config source that can be updated with new data.
RemoteConfigSourceA config source that loads configuration from a remote URL.
StaticConfigSourceA configuration source that reads from a static object, promise, iterable, or observable.

Functions

FunctionDescription
loadConfig(options)Load configuration data.
loadConfigSchema(options)Loads config schema for a Backstage instance.
mergeConfigSchemas(schemas)Given a list of configuration schemas from packages, merge them into a single json schema.
readEnvConfig(env)Read runtime configuration from the environment.

Interfaces

InterfaceDescription
BaseConfigSourcesOptionsCommon options for the default Backstage configuration sources.
ClosableConfigA config implementation that can be closed.
ConfigSourceA source of configuration data.
ConfigSourceDataThe data returned by ConfigSource.readConfigData().
ConfigSourcesDefaultForTargetsOptionsOptions for ConfigSources.defaultForTargets().
ConfigSourcesDefaultOptionsOptions for ConfigSources.default().
EnvConfigSourceOptionsOptions for EnvConfigSource.create().
FileConfigSourceOptionsOptions for FileConfigSource.create().
MutableConfigSourceOptionsOptions for MutableConfigSource.create().
ReadConfigDataOptionsOptions for ConfigSource.readConfigData().
RemoteConfigSourceOptionsOptions for RemoteConfigSource.create().
StaticConfigSourceOptionsOptions for StaticConfigSource.create().

Type Aliases

Type AliasDescription
AsyncConfigSourceGeneratorThe the generator returned by ConfigSource.readConfigData().
ConfigSchemaA loaded configuration schema that is ready to process configuration data.
ConfigSchemaProcessingOptionsOptions used to process configuration data with a schema.
ConfigSourceTargetA target to read configuration from.
ConfigTarget
ConfigVisibilityA type representing the possible configuration value visibilities
EnvFuncA custom function to be used for substitution withing configuration files.
LoadConfigOptionsOptions that control the loading of configuration files in the backend.
LoadConfigOptionsRemote
LoadConfigOptionsWatch
LoadConfigResultResults of loading configuration files.
LoadConfigSchemaOptionsOptions that control the loading of configuration schema files in the backend.
ParserA custom function to be used for parsing configuration content.
TransformFunc

A function used to transform primitive configuration values.

The "path" in the context is a JQ-style path to the current value from within the original object passed to filterByVisibility(). For example, "field.list[2]" would refer to: { field: [ "foo", "bar", "baz" -- this one ] }