@fabrika/auth-core 0.8.0 → 0.9.0-dev.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/dev-environment.ts +39 -0
- package/src/framework-variables.ts +5 -2
- package/src/index.ts +1 -0
package/package.json
CHANGED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
// What the platform's build hands the launcher of a `dev` environment: a generated file beside the generated entrypoint.
|
|
2
|
+
// The provider writes it, the application's own framework release reads it (ADR-0062: protocol, changed additively).
|
|
3
|
+
|
|
4
|
+
/** Relative to the application root. The build writes it after the checks, so no authored file can stand in for it. */
|
|
5
|
+
export const DEV_LAUNCHER_CONFIG_FILE = 'fabrika/dev.generated.json'
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* The module whose `runDevLauncher(process.env)` a `dev` environment's `run.start` calls instead of the serving entry.
|
|
9
|
+
* No file is generated for it: the checker allows `process.env` in the generated serving entry only.
|
|
10
|
+
*/
|
|
11
|
+
export const DEV_LAUNCHER_MODULE = '@fabrika/app/dev'
|
|
12
|
+
|
|
13
|
+
/** Where the launcher records what it holds, so a restart of the same container resumes it. A new container has none. */
|
|
14
|
+
export const DEV_LAUNCHER_STATE_FILE = 'fabrika/dev-state.json'
|
|
15
|
+
|
|
16
|
+
/** One command of the build's check chain, run by the shell in the application root. */
|
|
17
|
+
export interface DevLauncherCheck {
|
|
18
|
+
readonly name: string
|
|
19
|
+
readonly command: string
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export interface DevLauncherConfig {
|
|
23
|
+
readonly format: 1
|
|
24
|
+
readonly appId: string
|
|
25
|
+
/** The commit the bootstrap run built: what a new container holds before its first sync. */
|
|
26
|
+
readonly head: string
|
|
27
|
+
/** The port the serving entry listens on (`PORT`). */
|
|
28
|
+
readonly port: number
|
|
29
|
+
/** The contract's health endpoint, which says when a respawned application serves. */
|
|
30
|
+
readonly healthPath: string
|
|
31
|
+
/** The serving entry, as an argument vector run in the application root. */
|
|
32
|
+
readonly serve: readonly string[]
|
|
33
|
+
/** `fabrika db migrate`, as an argument vector; it runs only with the provisioning credential. */
|
|
34
|
+
readonly migrate: readonly string[]
|
|
35
|
+
/** The authored SPA commands of the build, each run by the shell when a web source changed. */
|
|
36
|
+
readonly spaBuild: readonly string[]
|
|
37
|
+
/** The build's check chain, which `run_checks` asks for. */
|
|
38
|
+
readonly checks: readonly DevLauncherCheck[]
|
|
39
|
+
}
|
|
@@ -159,8 +159,11 @@ export function frameworkVariableReference(text: string): string | null {
|
|
|
159
159
|
return null
|
|
160
160
|
}
|
|
161
161
|
|
|
162
|
-
/**
|
|
163
|
-
|
|
162
|
+
/**
|
|
163
|
+
* The platform's receivers an application reaches over the platform transport: `mail`, the relay of its jobs' mail, and
|
|
164
|
+
* `source`, which hands the launcher of a `dev` environment the files of the workspace bound to it (ADR-0064).
|
|
165
|
+
*/
|
|
166
|
+
export const PLATFORM_RECEIVERS = ['mail', 'source'] as const
|
|
164
167
|
|
|
165
168
|
export type PlatformReceiver = (typeof PLATFORM_RECEIVERS)[number]
|
|
166
169
|
|
package/src/index.ts
CHANGED