Function: defineConfigSchema()
defineConfigSchema<
P>(properties):TObject<PlatformProperties&P>
Defined in: packages/config/src/schema.ts:71
Builds a service's configuration schema.
Adds environment (a deliberate class, never inferred from NODE_ENV) and
secrets (driver, and root for the file driver). Neither has a default
in code: a deployment that does not say where it runs, or how it reaches its
secrets, fails at start rather than running under something nobody chose.
The schema is the single source of the typed config, the validation, the environment-override names and the generated configuration reference.
Type Parameters
P
P extends TProperties
Parameters
properties
P
Returns
TObject<PlatformProperties & P>
Throws
When properties redeclares a platform key.