@graftland/plugin-remote 0.3.3 → 0.4.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/README.md +18 -54
- package/README.zh-CN.md +17 -51
- package/README.zh-TW.md +17 -51
- package/dist/Auth.d.ts.map +1 -1
- package/dist/Auth.js.map +1 -1
- package/dist/Config.d.ts +1151 -0
- package/dist/Config.d.ts.map +1 -0
- package/dist/Config.js +183 -0
- package/dist/Config.js.map +1 -0
- package/dist/Contract.d.ts +1 -1
- package/dist/Contract.d.ts.map +1 -1
- package/dist/Contract.js +32 -1
- package/dist/Contract.js.map +1 -1
- package/dist/Instance.d.ts.map +1 -1
- package/dist/Instance.js.map +1 -1
- package/dist/Testing.d.ts +1 -1
- package/dist/Testing.d.ts.map +1 -1
- package/dist/Testing.js.map +1 -1
- package/dist/Transport.d.ts +1 -1
- package/dist/Transport.d.ts.map +1 -1
- package/dist/Transport.js.map +1 -1
- package/dist/cli.d.ts +4 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +25 -0
- package/dist/cli.js.map +1 -0
- package/dist/host/auth/bearer.d.ts.map +1 -1
- package/dist/host/auth/bearer.js +4 -2
- package/dist/host/auth/bearer.js.map +1 -1
- package/dist/host/auth/jwt.d.ts.map +1 -1
- package/dist/host/auth/jwt.js +4 -2
- package/dist/host/auth/jwt.js.map +1 -1
- package/dist/host/auth/mtls.d.ts +3 -7
- package/dist/host/auth/mtls.d.ts.map +1 -1
- package/dist/host/auth/mtls.js +13 -14
- package/dist/host/auth/mtls.js.map +1 -1
- package/dist/host/auth/none.d.ts +1 -1
- package/dist/host/auth/none.js +7 -5
- package/dist/host/auth/none.js.map +1 -1
- package/dist/host/command.d.ts +1 -1
- package/dist/host/command.d.ts.map +1 -1
- package/dist/host/command.js +11 -9
- package/dist/host/command.js.map +1 -1
- package/dist/host/local.d.ts.map +1 -1
- package/dist/host/local.js +9 -30
- package/dist/host/local.js.map +1 -1
- package/dist/host/unix.d.ts +1 -1
- package/dist/host/unix.d.ts.map +1 -1
- package/dist/host/unix.js +13 -9
- package/dist/host/unix.js.map +1 -1
- package/dist/host/websocket.d.ts +1 -1
- package/dist/host/websocket.d.ts.map +1 -1
- package/dist/host/websocket.js +11 -8
- package/dist/host/websocket.js.map +1 -1
- package/dist/host/worker.d.ts +1 -1
- package/dist/host/worker.d.ts.map +1 -1
- package/dist/host/worker.js +13 -9
- package/dist/host/worker.js.map +1 -1
- package/dist/index.d.ts +6 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +30 -64
- package/dist/index.js.map +1 -1
- package/dist/internal/Certificates.js.map +1 -1
- package/dist/internal/FailureGroup.js +6 -6
- package/dist/internal/FailureGroup.js.map +1 -1
- package/dist/internal/Peer.js.map +1 -1
- package/dist/internal/{ServeLifecycle.js → RunnerLifecycle.js} +6 -6
- package/dist/internal/RunnerLifecycle.js.map +1 -0
- package/dist/internal/Supervisor.js.map +1 -1
- package/dist/internal/assembly.d.ts +3 -3
- package/dist/internal/assembly.js +8 -8
- package/dist/internal/assembly.js.map +1 -1
- package/dist/internal/auth/config.d.ts +27 -0
- package/dist/internal/auth/config.d.ts.map +1 -0
- package/dist/internal/auth/config.js +29 -0
- package/dist/internal/auth/config.js.map +1 -0
- package/dist/internal/auth/mtls.js.map +1 -1
- package/dist/internal/auth/token.js.map +1 -1
- package/dist/internal/auth/tokenCredentials.d.ts +1 -1
- package/dist/internal/auth/tokenCredentials.d.ts.map +1 -1
- package/dist/internal/auth/tokenCredentials.js +1 -1
- package/dist/internal/auth/tokenCredentials.js.map +1 -1
- package/dist/internal/child.js +3 -3
- package/dist/internal/child.js.map +1 -1
- package/dist/internal/childMain.js +47 -0
- package/dist/internal/childMain.js.map +1 -0
- package/dist/internal/childRuntime.js +8 -8
- package/dist/internal/childRuntime.js.map +1 -1
- package/dist/internal/cleanup.js +3 -3
- package/dist/internal/cleanup.js.map +1 -1
- package/dist/internal/contract.js.map +1 -1
- package/dist/internal/credentials.d.ts +3 -2
- package/dist/internal/credentials.d.ts.map +1 -1
- package/dist/internal/credentials.js +1 -1
- package/dist/internal/credentials.js.map +1 -1
- package/dist/internal/directTransport.js.map +1 -1
- package/dist/internal/entry.d.ts +104 -26
- package/dist/internal/entry.d.ts.map +1 -1
- package/dist/internal/entry.js +22 -9
- package/dist/internal/entry.js.map +1 -1
- package/dist/internal/entryConfig.d.ts +2 -202
- package/dist/internal/entryConfig.js +2 -136
- package/dist/internal/entryConfig.js.map +1 -1
- package/dist/internal/execution.d.ts +4 -4
- package/dist/internal/execution.js +11 -11
- package/dist/internal/execution.js.map +1 -1
- package/dist/internal/follow.js +1 -1
- package/dist/internal/follow.js.map +1 -1
- package/dist/internal/forkTree.js.map +1 -1
- package/dist/internal/host/local.js.map +1 -1
- package/dist/internal/host/runner.js +4 -4
- package/dist/internal/host/runner.js.map +1 -1
- package/dist/internal/host.js +2 -2
- package/dist/internal/host.js.map +1 -1
- package/dist/internal/importer.js +1 -1
- package/dist/internal/importer.js.map +1 -1
- package/dist/internal/listenerStartup.js +1 -1
- package/dist/internal/listenerStartup.js.map +1 -1
- package/dist/internal/loadModule.js.map +1 -1
- package/dist/internal/platform.js +1 -9
- package/dist/internal/port.d.ts +1 -1
- package/dist/internal/port.js +2 -2
- package/dist/internal/port.js.map +1 -1
- package/dist/internal/runner/Bootstrap.js.map +1 -1
- package/dist/internal/runner/Connection.d.ts +3 -2
- package/dist/internal/runner/Connection.js +6 -6
- package/dist/internal/runner/Connection.js.map +1 -1
- package/dist/internal/runner/Execution.js +6 -6
- package/dist/internal/runner/Execution.js.map +1 -1
- package/dist/internal/runner/Local.js +1 -1
- package/dist/internal/runner/Local.js.map +1 -1
- package/dist/internal/runner/Lock.js.map +1 -1
- package/dist/internal/runner/Multiplex.js.map +1 -1
- package/dist/internal/runner/Packages.js.map +1 -1
- package/dist/internal/runner/ProcessObservation.js.map +1 -1
- package/dist/internal/runner/Processes.js.map +1 -1
- package/dist/internal/runner/Retention.js.map +1 -1
- package/dist/internal/runner/Store.js.map +1 -1
- package/dist/internal/runner/Supervisor.js +5 -5
- package/dist/internal/runner/Supervisor.js.map +1 -1
- package/dist/internal/runner/Watchdog.js.map +1 -1
- package/dist/internal/runner/Wire.d.ts +1 -1
- package/dist/internal/runner/Wire.js.map +1 -1
- package/dist/internal/runner/accept.js +2 -2
- package/dist/internal/runner/accept.js.map +1 -1
- package/dist/internal/runner/command.js +1 -1
- package/dist/internal/runner/command.js.map +1 -1
- package/dist/internal/runner/connectionEnded.js +1 -1
- package/dist/internal/runner/connectionEnded.js.map +1 -1
- package/dist/internal/runner/model.d.ts.map +1 -1
- package/dist/internal/runner/model.js.map +1 -1
- package/dist/internal/services.d.ts.map +1 -1
- package/dist/internal/services.js +1 -1
- package/dist/internal/services.js.map +1 -1
- package/dist/internal/socketChannel.js.map +1 -1
- package/dist/internal/stdioChannel.js.map +1 -1
- package/dist/internal/supervisorPlugin.js +48 -1
- package/dist/internal/supervisorPlugin.js.map +1 -1
- package/dist/internal/transportOptions.d.ts.map +1 -1
- package/dist/internal/watchdogMain.js +5 -3
- package/dist/internal/watchdogMain.js.map +1 -1
- package/dist/internal/websocket.js.map +1 -1
- package/dist/internal/websocketServer.js +1 -1
- package/dist/internal/websocketServer.js.map +1 -1
- package/dist/internal/workerChannel.js.map +1 -1
- package/dist/internal/workerMain.js +13 -6
- package/dist/internal/workerMain.js.map +1 -1
- package/dist/runner/auth/bearer.d.ts +3 -5
- package/dist/runner/auth/bearer.d.ts.map +1 -1
- package/dist/runner/auth/bearer.js +13 -11
- package/dist/runner/auth/bearer.js.map +1 -1
- package/dist/runner/auth/jwt.d.ts +4 -18
- package/dist/runner/auth/jwt.d.ts.map +1 -1
- package/dist/runner/auth/jwt.js +16 -28
- package/dist/runner/auth/jwt.js.map +1 -1
- package/dist/runner/auth/mtls.d.ts +3 -6
- package/dist/runner/auth/mtls.d.ts.map +1 -1
- package/dist/runner/auth/mtls.js +13 -29
- package/dist/runner/auth/mtls.js.map +1 -1
- package/dist/runner/auth/none.d.ts +1 -1
- package/dist/runner/auth/none.js +7 -5
- package/dist/runner/auth/none.js.map +1 -1
- package/dist/runner/index.d.ts +3 -308
- package/dist/runner/index.d.ts.map +1 -1
- package/dist/runner/index.js +62 -30
- package/dist/runner/index.js.map +1 -1
- package/dist/runner/stdio.d.ts +1 -1
- package/dist/runner/stdio.d.ts.map +1 -1
- package/dist/runner/stdio.js +11 -9
- package/dist/runner/stdio.js.map +1 -1
- package/dist/runner/unix.d.ts +1 -1
- package/dist/runner/unix.d.ts.map +1 -1
- package/dist/runner/unix.js +10 -8
- package/dist/runner/unix.js.map +1 -1
- package/dist/runner/websocket.d.ts +1 -1
- package/dist/runner/websocket.d.ts.map +1 -1
- package/dist/runner/websocket.js +12 -10
- package/dist/runner/websocket.js.map +1 -1
- package/package.json +14 -12
- package/schema.json +2269 -0
- package/src/Auth.ts +8 -2
- package/src/Config.ts +196 -0
- package/src/Contract.ts +12 -3
- package/src/Instance.ts +1 -0
- package/src/Testing.ts +6 -4
- package/src/Transport.ts +12 -3
- package/src/cli.ts +60 -0
- package/src/host/auth/bearer.ts +1 -0
- package/src/host/auth/jwt.ts +1 -0
- package/src/host/auth/mtls.ts +7 -12
- package/src/host/auth/none.ts +3 -1
- package/src/host/command.ts +8 -5
- package/src/host/local.ts +4 -2
- package/src/host/unix.ts +11 -7
- package/src/host/websocket.ts +10 -7
- package/src/host/worker.ts +8 -5
- package/src/index.ts +36 -23
- package/src/internal/Certificates.ts +1 -0
- package/src/internal/FailureGroup.ts +5 -3
- package/src/internal/Peer.ts +1 -0
- package/src/internal/{ServeLifecycle.ts → RunnerLifecycle.ts} +7 -5
- package/src/internal/Supervisor.ts +5 -4
- package/src/internal/assembly.ts +11 -9
- package/src/internal/auth/config.ts +44 -0
- package/src/internal/auth/mtls.ts +1 -0
- package/src/internal/auth/token.ts +1 -0
- package/src/internal/auth/tokenCredentials.ts +4 -2
- package/src/internal/child.ts +8 -6
- package/src/{bin.ts → internal/childMain.ts} +16 -61
- package/src/internal/childRuntime.ts +12 -10
- package/src/internal/cleanup.ts +3 -2
- package/src/internal/contract.ts +1 -0
- package/src/internal/credentials.ts +3 -1
- package/src/internal/directTransport.ts +9 -2
- package/src/internal/entry.ts +53 -16
- package/src/internal/entryConfig.ts +10 -132
- package/src/internal/execution.ts +17 -15
- package/src/internal/follow.ts +2 -1
- package/src/internal/forkTree.ts +2 -1
- package/src/internal/host/local.ts +1 -0
- package/src/internal/host/runner.ts +7 -5
- package/src/internal/host.ts +9 -8
- package/src/internal/importer.ts +3 -2
- package/src/internal/listenerStartup.ts +4 -2
- package/src/internal/loadModule.ts +1 -0
- package/src/internal/platform.ts +1 -12
- package/src/internal/port.ts +11 -6
- package/src/internal/runner/Bootstrap.ts +1 -0
- package/src/internal/runner/Connection.ts +13 -11
- package/src/internal/runner/Execution.ts +14 -13
- package/src/internal/runner/Local.ts +3 -2
- package/src/internal/runner/Lock.ts +1 -0
- package/src/internal/runner/Multiplex.ts +2 -1
- package/src/internal/runner/Packages.ts +7 -5
- package/src/internal/runner/ProcessObservation.ts +2 -1
- package/src/internal/runner/Processes.ts +3 -1
- package/src/internal/runner/Retention.ts +1 -0
- package/src/internal/runner/Store.ts +3 -2
- package/src/internal/runner/Supervisor.ts +22 -20
- package/src/internal/runner/Watchdog.ts +3 -1
- package/src/internal/runner/Wire.ts +13 -12
- package/src/internal/runner/accept.ts +6 -5
- package/src/internal/runner/command.ts +3 -2
- package/src/internal/runner/connectionEnded.ts +2 -1
- package/src/internal/runner/model.ts +5 -3
- package/src/internal/services.ts +9 -2
- package/src/internal/socketChannel.ts +2 -1
- package/src/internal/stdioChannel.ts +4 -2
- package/src/internal/supervisorPlugin.ts +10 -8
- package/src/internal/transportOptions.ts +1 -0
- package/src/internal/watchdogMain.ts +5 -3
- package/src/internal/websocket.ts +5 -2
- package/src/internal/websocketServer.ts +6 -4
- package/src/internal/workerChannel.ts +1 -0
- package/src/internal/workerMain.ts +21 -5
- package/src/runner/auth/bearer.ts +10 -6
- package/src/runner/auth/jwt.ts +10 -41
- package/src/runner/auth/mtls.ts +6 -3
- package/src/runner/auth/none.ts +3 -1
- package/src/runner/index.ts +102 -11
- package/src/runner/stdio.ts +15 -10
- package/src/runner/unix.ts +7 -4
- package/src/runner/websocket.ts +9 -7
- package/dist/Auth-BElTC9_X.js +0 -6
- package/dist/Bootstrap-H9gDsgsC.js +0 -9
- package/dist/ConfigDirectory-BCC6q2R4.js +0 -5
- package/dist/Contract-DsJtisvL.js +0 -83
- package/dist/Errors-DYhsGZcZ.js +0 -58
- package/dist/FailureGroup-BgT73AaR.js +0 -63
- package/dist/Framing-G9eSaeLb.js +0 -61
- package/dist/Graft-B71CPA2Y.js +0 -996
- package/dist/Packages-AgoCGotL.js +0 -108
- package/dist/Peer-DXeVrGBh.js +0 -342
- package/dist/ProcessObservation-gLgGirYv.js +0 -38
- package/dist/ServeLifecycle-Bd1FPJ6e.js +0 -24
- package/dist/Transport-DULzpsgR.js +0 -6
- package/dist/WatchdogProtocol-BZmVxrBP.js +0 -17
- package/dist/bin.js +0 -28276
- package/dist/bin.js.map +0 -1
- package/dist/childRuntime-Bm3iSg_N.js +0 -192
- package/dist/command-9zrHdbwT.js +0 -7
- package/dist/connectionEnded-BwcxQ7W8.js +0 -54
- package/dist/directTransport-DrexuPSm.js +0 -5
- package/dist/entry-psOpX3Bj.js +0 -736
- package/dist/importer-Cvf88eAY.js +0 -344
- package/dist/internal/ServeLifecycle.js.map +0 -1
- package/dist/internal/entryConfig.d.ts.map +0 -1
- package/dist/internal/platform.js.map +0 -1
- package/dist/internal/release.js +0 -25
- package/dist/internal/release.js.map +0 -1
- package/dist/internal/serve.js +0 -60
- package/dist/internal/serve.js.map +0 -1
- package/dist/port--3x2zJ4D.js +0 -285
- package/dist/release-DfZPuIcK.js +0 -23
- package/dist/rolldown-runtime-DYf_mQCB.js +0 -34
- package/dist/socketChannel-CJvL2DiB.js +0 -3658
- package/dist/supervisorPlugin-t6Z6PrhD.js +0 -733
- package/dist/token-CYBNNlhS.js +0 -17
- package/dist/tokenCredentials-CbCuk-Rt.js +0 -31
- package/dist/websocketServer-NQhODlEt.js +0 -60
- package/dist/workerChannel-C8hhBJzA.js +0 -27
- package/src/internal/release.ts +0 -72
- package/src/internal/serve.ts +0 -119
- /package/dist/{bin.d.ts → internal/childMain.d.ts} +0 -0
package/src/internal/services.ts
CHANGED
|
@@ -1,7 +1,14 @@
|
|
|
1
1
|
import { Array, Context, Effect, Record } from "effect"
|
|
2
|
+
import {
|
|
3
|
+
RpcClient,
|
|
4
|
+
RpcServer,
|
|
5
|
+
type Rpc,
|
|
6
|
+
type RpcClientError,
|
|
7
|
+
type RpcGroup,
|
|
8
|
+
} from "effect/rpc"
|
|
9
|
+
|
|
2
10
|
import { Graft } from "@graftland/graft"
|
|
3
|
-
|
|
4
|
-
import type { Rpc, RpcClientError, RpcGroup } from "effect/rpc"
|
|
11
|
+
|
|
5
12
|
import type { Service } from "../Contract"
|
|
6
13
|
|
|
7
14
|
export const service = <
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { Cause, Effect, Exit, Sink, Stream } from "effect"
|
|
2
2
|
import { Socket } from "effect/socket"
|
|
3
|
+
|
|
3
4
|
import { TransportError } from "../Errors"
|
|
4
|
-
import {
|
|
5
|
+
import { decoder, encode, FrameError, isCompleteFrame } from "./runner/Framing"
|
|
5
6
|
|
|
6
7
|
/** WebSocket boundaries are a wire compatibility detail, not Channel chunk boundaries. */
|
|
7
8
|
export const fromSocket = Effect.fnUntraced(function* (socket: Socket.Socket) {
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { NodeSink } from "@effect/platform-node"
|
|
2
|
-
import { Cause, Effect, Stdio, Stream } from "effect"
|
|
3
1
|
// @effect-diagnostics-next-line nodeBuiltinImport:off -- Node's extra inherited descriptor carries protocol output separately from console output.
|
|
4
2
|
import { createWriteStream } from "node:fs"
|
|
3
|
+
|
|
4
|
+
import { Cause, Effect, Stdio, Stream } from "effect"
|
|
5
|
+
import { NodeSink } from "@effect/platform-node"
|
|
6
|
+
|
|
5
7
|
import { TransportError } from "../Errors"
|
|
6
8
|
import type * as Port from "./port"
|
|
7
9
|
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { Graft, Plugin } from "@graftland/graft"
|
|
2
1
|
import {
|
|
3
2
|
Context,
|
|
4
3
|
Effect,
|
|
@@ -11,15 +10,18 @@ import {
|
|
|
11
10
|
} from "effect"
|
|
12
11
|
import { Digest, SecureRandom } from "effect/crypto"
|
|
13
12
|
import { ChildProcessSpawner } from "effect/process"
|
|
14
|
-
|
|
15
|
-
import {
|
|
13
|
+
|
|
14
|
+
import { Graft, Plugin } from "@graftland/graft"
|
|
16
15
|
import { ConfigDirectory } from "@graftland/loader"
|
|
16
|
+
|
|
17
|
+
import { PositiveDuration } from "./config"
|
|
18
|
+
import { accept } from "./runner/accept"
|
|
19
|
+
import * as Execution from "./runner/Execution"
|
|
17
20
|
import * as Lock from "./runner/Lock"
|
|
18
21
|
import * as Stores from "./runner/Store"
|
|
19
|
-
import * as Execution from "./runner/Execution"
|
|
20
22
|
import * as Engine from "./runner/Supervisor"
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
+
import * as Lifecycle from "./RunnerLifecycle"
|
|
24
|
+
import { Supervisor } from "./Supervisor"
|
|
23
25
|
|
|
24
26
|
export const Config = Schema.Struct({
|
|
25
27
|
root: Schema.String,
|
|
@@ -31,7 +33,7 @@ export default Plugin.make({
|
|
|
31
33
|
name: "remote-supervisor",
|
|
32
34
|
config: Config,
|
|
33
35
|
inject: [
|
|
34
|
-
Plugin.optional(Lifecycle.
|
|
36
|
+
Plugin.optional(Lifecycle.RunnerLifecycle),
|
|
35
37
|
FileSystem.FileSystem,
|
|
36
38
|
Path.Path,
|
|
37
39
|
ChildProcessSpawner.ChildProcessSpawner,
|
|
@@ -39,7 +41,7 @@ export default Plugin.make({
|
|
|
39
41
|
Digest.Digest,
|
|
40
42
|
],
|
|
41
43
|
apply: Effect.fnUntraced(function* (options) {
|
|
42
|
-
const lifecycle = yield* Effect.serviceOption(Lifecycle.
|
|
44
|
+
const lifecycle = yield* Effect.serviceOption(Lifecycle.RunnerLifecycle)
|
|
43
45
|
const resources = yield* Lifecycle.resources(lifecycle)
|
|
44
46
|
const path = yield* Path.Path
|
|
45
47
|
const directory = yield* ConfigDirectory.pipe(
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
/** Executable worker: fd 4 and the lease timer remain independent of the plugin thread. */
|
|
2
|
-
import { NodeRuntime, NodeStream } from "@effect/platform-node"
|
|
3
|
-
import { Clock, Effect, FiberHandle, Ref, Schema, Stream } from "effect"
|
|
4
2
|
import { Socket } from "node:net"
|
|
5
|
-
import { parentPort } from "node:worker_threads"
|
|
6
3
|
import process from "node:process"
|
|
4
|
+
import { parentPort } from "node:worker_threads"
|
|
5
|
+
|
|
6
|
+
import { Clock, Effect, FiberHandle, Ref, Schema, Stream } from "effect"
|
|
7
|
+
import { NodeRuntime, NodeStream } from "@effect/platform-node"
|
|
8
|
+
|
|
7
9
|
import { CommandJson, Notice } from "./runner/WatchdogProtocol"
|
|
8
10
|
|
|
9
11
|
// The runner machine is trusted. A suspended machine cannot enforce a deadline until it resumes.
|
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
import { Array, Effect, Layer, Redacted, Schema } from "effect"
|
|
2
2
|
import { Socket } from "effect/socket"
|
|
3
|
+
|
|
3
4
|
import WS from "ws"
|
|
5
|
+
|
|
4
6
|
import type { ClientCertificate } from "../Auth"
|
|
5
7
|
import type { Properties } from "../Transport"
|
|
8
|
+
import { headerSize, maxPayload } from "./runner/Framing"
|
|
9
|
+
import type { WebsocketOptions } from "./transportOptions"
|
|
10
|
+
|
|
6
11
|
interface PreparedCredentials {
|
|
7
12
|
readonly certificate?: ClientCertificate
|
|
8
13
|
readonly authorization?: Redacted.Redacted<string>
|
|
9
14
|
}
|
|
10
|
-
import type { WebsocketOptions } from "./transportOptions"
|
|
11
|
-
import { headerSize, maxPayload } from "./runner/Framing"
|
|
12
15
|
|
|
13
16
|
export const protocol = "graft-remote.v1"
|
|
14
17
|
export const path = "/graft"
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TLSSocket } from "node:tls"
|
|
2
|
+
|
|
2
3
|
import {
|
|
3
4
|
Array,
|
|
4
5
|
Cause,
|
|
@@ -11,15 +12,16 @@ import {
|
|
|
11
12
|
} from "effect"
|
|
12
13
|
import { HttpServerRequest, HttpServerResponse } from "effect/http"
|
|
13
14
|
import type { Socket } from "effect/socket"
|
|
14
|
-
import {
|
|
15
|
+
import { NodeHttpServer, NodeHttpServerRequest } from "@effect/platform-node"
|
|
16
|
+
|
|
15
17
|
import {
|
|
18
|
+
TransportError,
|
|
16
19
|
type AuthenticationFailed,
|
|
17
20
|
type AuthenticatorUnavailable,
|
|
18
|
-
TransportError,
|
|
19
21
|
} from "../Errors"
|
|
20
22
|
import type { Accept, Handshake, Serving } from "../Transport"
|
|
21
23
|
import * as Channel from "./socketChannel"
|
|
22
|
-
import { path,
|
|
24
|
+
import { path, payloadLimit, protocol } from "./websocket"
|
|
23
25
|
|
|
24
26
|
const rejection = (error: AuthenticationFailed | AuthenticatorUnavailable) =>
|
|
25
27
|
error._tag === "AuthenticatorUnavailable"
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
/** Executable entry for a direct worker; platform services belong to this thread. */
|
|
2
|
-
import { Graft } from "@graftland/graft"
|
|
3
|
-
import { NodeRuntime } from "@effect/platform-node"
|
|
4
|
-
import { Effect, Layer, Schema } from "effect"
|
|
5
2
|
import { parentPort, workerData } from "node:worker_threads"
|
|
3
|
+
|
|
4
|
+
import { Cause, Effect, Layer, Logger, Schema } from "effect"
|
|
5
|
+
import { NodeRuntime } from "@effect/platform-node"
|
|
6
|
+
|
|
7
|
+
import { Graft } from "@graftland/graft"
|
|
8
|
+
|
|
6
9
|
import { load, run } from "./childRuntime"
|
|
10
|
+
import { platform } from "./platform"
|
|
7
11
|
import { Bootstrap } from "./workerBootstrap"
|
|
8
12
|
import * as Channel from "./workerChannel"
|
|
9
|
-
import { platform } from "./platform"
|
|
10
13
|
|
|
11
14
|
const main = Effect.scoped(
|
|
12
15
|
Effect.gen(function* () {
|
|
@@ -19,5 +22,18 @@ const main = Effect.scoped(
|
|
|
19
22
|
}),
|
|
20
23
|
)
|
|
21
24
|
NodeRuntime.runMain(
|
|
22
|
-
|
|
25
|
+
Effect.scoped(
|
|
26
|
+
Effect.gen(function* () {
|
|
27
|
+
const context = yield* Layer.build(
|
|
28
|
+
Graft.layer.pipe(Layer.provide(platform)),
|
|
29
|
+
)
|
|
30
|
+
return yield* main.pipe(Effect.provideContext(context))
|
|
31
|
+
}),
|
|
32
|
+
).pipe(
|
|
33
|
+
Effect.tapCause((cause) =>
|
|
34
|
+
Cause.hasInterruptsOnly(cause) ? Effect.void : Effect.logError(cause),
|
|
35
|
+
),
|
|
36
|
+
Effect.provideService(Logger.LogToStderr, true),
|
|
37
|
+
),
|
|
38
|
+
{ disableErrorReporting: true },
|
|
23
39
|
)
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
1
|
+
// @effect-diagnostics-next-line nodeBuiltinImport:off -- Token digests use Node's constant-time comparison
|
|
2
|
+
import { timingSafeEqual } from "node:crypto"
|
|
3
|
+
|
|
3
4
|
import {
|
|
4
5
|
Array,
|
|
5
6
|
Effect,
|
|
6
7
|
FileSystem,
|
|
8
|
+
Option,
|
|
7
9
|
Path,
|
|
8
10
|
Record,
|
|
9
11
|
Redacted,
|
|
@@ -11,13 +13,15 @@ import {
|
|
|
11
13
|
} from "effect"
|
|
12
14
|
import { Digest } from "effect/crypto"
|
|
13
15
|
import { Hex } from "effect/encoding"
|
|
14
|
-
|
|
15
|
-
import {
|
|
16
|
-
import { Authenticator } from "../../Auth"
|
|
16
|
+
|
|
17
|
+
import { Graft, Plugin } from "@graftland/graft"
|
|
17
18
|
import { ConfigDirectory } from "@graftland/loader"
|
|
19
|
+
|
|
20
|
+
import { Authenticator } from "../../Auth"
|
|
21
|
+
import { Bearer as Config } from "../../internal/auth/config"
|
|
18
22
|
import * as Token from "../../internal/auth/token"
|
|
19
23
|
|
|
20
|
-
export
|
|
24
|
+
export { Config }
|
|
21
25
|
const Tokens = Schema.fromJsonString(
|
|
22
26
|
Schema.Record(
|
|
23
27
|
Schema.String.check(Schema.isPattern(/^[0-9a-fA-F]{64}$/)),
|
package/src/runner/auth/jwt.ts
CHANGED
|
@@ -1,50 +1,19 @@
|
|
|
1
|
-
import { Option } from "effect"
|
|
2
|
-
import { Graft, Plugin } from "@graftland/graft"
|
|
3
|
-
import {
|
|
4
|
-
Cause,
|
|
5
|
-
Duration,
|
|
6
|
-
Effect,
|
|
7
|
-
FileSystem,
|
|
8
|
-
Layer,
|
|
9
|
-
Path,
|
|
10
|
-
Schema,
|
|
11
|
-
} from "effect"
|
|
12
|
-
import { Jwk, Jwks, Jwt } from "effect/jose"
|
|
1
|
+
import { Cause, Effect, FileSystem, Layer, Option, Path, Schema } from "effect"
|
|
13
2
|
import { Signature } from "effect/crypto"
|
|
14
3
|
import { HttpClient } from "effect/http"
|
|
15
|
-
import {
|
|
4
|
+
import { Jwk, Jwks, Jwt } from "effect/jose"
|
|
5
|
+
|
|
6
|
+
import { Graft, Plugin } from "@graftland/graft"
|
|
16
7
|
import { ConfigDirectory } from "@graftland/loader"
|
|
8
|
+
|
|
9
|
+
import { Authenticator } from "../../Auth"
|
|
17
10
|
import { AuthenticationFailed, AuthenticatorUnavailable } from "../../Errors"
|
|
11
|
+
import { Jwt as Config } from "../../internal/auth/config"
|
|
18
12
|
import * as Token from "../../internal/auth/token"
|
|
19
13
|
|
|
20
|
-
export
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
Duration.isFinite(duration) && Duration.toMillis(duration) >= 0,
|
|
24
|
-
{ expected: "a finite, non-negative duration" },
|
|
25
|
-
),
|
|
26
|
-
)
|
|
27
|
-
export const Config = Schema.Struct({
|
|
28
|
-
issuer: Schema.NonEmptyString,
|
|
29
|
-
audience: Schema.NonEmptyArray(Schema.NonEmptyString),
|
|
30
|
-
algorithms: Schema.NonEmptyArray(Jwk.AsymmetricAlgorithm),
|
|
31
|
-
identityClaim: Schema.NonEmptyString.pipe(
|
|
32
|
-
Schema.withDecodingDefaultKey(Effect.succeed("sub")),
|
|
33
|
-
),
|
|
34
|
-
clockTolerance: ClockTolerance.pipe(
|
|
35
|
-
Schema.withDecodingDefaultKey(Effect.succeed("5 seconds")),
|
|
36
|
-
),
|
|
37
|
-
keys: Schema.Union([
|
|
38
|
-
Schema.Struct({
|
|
39
|
-
jwksUrl: Schema.String,
|
|
40
|
-
publicKey: Schema.optionalKey(Schema.Never),
|
|
41
|
-
}),
|
|
42
|
-
Schema.Struct({
|
|
43
|
-
publicKey: Schema.String,
|
|
44
|
-
jwksUrl: Schema.optionalKey(Schema.Never),
|
|
45
|
-
}),
|
|
46
|
-
]),
|
|
47
|
-
})
|
|
14
|
+
export { ClockTolerance } from "../../internal/auth/config"
|
|
15
|
+
|
|
16
|
+
export { Config }
|
|
48
17
|
const keys = Effect.fnUntraced(function* (config: typeof Config.Type) {
|
|
49
18
|
if (config.keys.jwksUrl !== undefined)
|
|
50
19
|
return Jwks.layerRemote({ url: config.keys.jwksUrl })
|
package/src/runner/auth/mtls.ts
CHANGED
|
@@ -1,10 +1,13 @@
|
|
|
1
|
+
import { Effect, FileSystem, Option, Path } from "effect"
|
|
2
|
+
|
|
1
3
|
import { Graft, Plugin } from "@graftland/graft"
|
|
2
|
-
import { Effect, FileSystem, Option, Path, Schema } from "effect"
|
|
3
|
-
import { Authenticator, type AuthenticatorApi } from "../../Auth"
|
|
4
4
|
import { ConfigDirectory } from "@graftland/loader"
|
|
5
|
+
|
|
6
|
+
import { Authenticator, type AuthenticatorApi } from "../../Auth"
|
|
7
|
+
import { Mtls as Config } from "../../internal/auth/config"
|
|
5
8
|
import { identityFromSubjectAltName } from "../../internal/auth/mtls"
|
|
6
9
|
|
|
7
|
-
export
|
|
10
|
+
export { Config }
|
|
8
11
|
const read = Effect.fnUntraced(function* (ca: string) {
|
|
9
12
|
const fs = yield* FileSystem.FileSystem
|
|
10
13
|
const path = yield* Path.Path
|
package/src/runner/auth/none.ts
CHANGED
package/src/runner/index.ts
CHANGED
|
@@ -1,13 +1,27 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
Array,
|
|
3
|
+
Cause,
|
|
4
|
+
Deferred,
|
|
5
|
+
Effect,
|
|
6
|
+
Exit,
|
|
7
|
+
Option,
|
|
8
|
+
Path,
|
|
9
|
+
Schema,
|
|
10
|
+
Stream,
|
|
11
|
+
} from "effect"
|
|
2
12
|
import { SecureRandom } from "effect/crypto"
|
|
3
|
-
|
|
13
|
+
|
|
14
|
+
import { Application, ProtocolOutput } from "@graftland/cli/Application"
|
|
15
|
+
import { Graft, Plugin, type Fork } from "@graftland/graft"
|
|
4
16
|
import { ModuleResolver } from "@graftland/loader"
|
|
5
|
-
|
|
6
|
-
import * as Configuration from "../internal/entryConfig"
|
|
7
|
-
import { boundary, resolve } from "../internal/entry"
|
|
17
|
+
|
|
8
18
|
import * as Assembly from "../internal/assembly"
|
|
9
|
-
import
|
|
19
|
+
import { cleanupCause } from "../internal/cleanup"
|
|
20
|
+
import { boundary, resolve } from "../internal/entry"
|
|
21
|
+
import * as Configuration from "../internal/entryConfig"
|
|
10
22
|
import { follow } from "../internal/follow"
|
|
23
|
+
import * as Startup from "../internal/listenerStartup"
|
|
24
|
+
import * as Lifecycle from "../internal/RunnerLifecycle"
|
|
11
25
|
import { Supervisor } from "../internal/Supervisor"
|
|
12
26
|
import supervisor, {
|
|
13
27
|
Config as SupervisorConfig,
|
|
@@ -45,7 +59,12 @@ const startListener = Effect.fnUntraced(function* (
|
|
|
45
59
|
const owner = Plugin.make({
|
|
46
60
|
name: "remote-supervised-runtime",
|
|
47
61
|
config: Configuration.Runner,
|
|
48
|
-
inject: [
|
|
62
|
+
inject: [
|
|
63
|
+
ModuleResolver.ModuleResolver,
|
|
64
|
+
Path.Path,
|
|
65
|
+
SecureRandom.SecureRandom,
|
|
66
|
+
Plugin.optional(Application),
|
|
67
|
+
],
|
|
49
68
|
apply: Effect.fnUntraced(function* (config) {
|
|
50
69
|
const options = yield* Schema.encodeEffect(SupervisorConfig)(config)
|
|
51
70
|
const engine = yield* Graft.plugin(supervisor, options)
|
|
@@ -61,6 +80,21 @@ const owner = Plugin.make({
|
|
|
61
80
|
{ concurrency: "unbounded" },
|
|
62
81
|
)
|
|
63
82
|
yield* Startup.validate(descriptions)
|
|
83
|
+
const protocol = yield* ProtocolOutput
|
|
84
|
+
if (
|
|
85
|
+
Array.some(
|
|
86
|
+
descriptions,
|
|
87
|
+
(description) => description.properties.protocol === "stdio",
|
|
88
|
+
) !== protocol
|
|
89
|
+
)
|
|
90
|
+
return yield* Lifecycle.StartupError.make({
|
|
91
|
+
detail:
|
|
92
|
+
"A stdio runner requires graft start --stdio and exactly one stdio listener",
|
|
93
|
+
})
|
|
94
|
+
if (protocol) {
|
|
95
|
+
const application = yield* Effect.serviceOption(Application)
|
|
96
|
+
if (Option.isSome(application)) yield* application.value.claimProtocol
|
|
97
|
+
}
|
|
64
98
|
yield* Deferred.succeed(begin, undefined)
|
|
65
99
|
yield* Effect.forEach(
|
|
66
100
|
listeners,
|
|
@@ -85,13 +119,70 @@ const owner = Plugin.make({
|
|
|
85
119
|
)
|
|
86
120
|
}),
|
|
87
121
|
})
|
|
122
|
+
const shutdown = Effect.fnUntraced(function* (
|
|
123
|
+
fork: Fork.Fork,
|
|
124
|
+
lifecycle: typeof Lifecycle.RunnerLifecycle.Service,
|
|
125
|
+
) {
|
|
126
|
+
const disposed = yield* Effect.exit(fork.dispose)
|
|
127
|
+
const result = yield* Deferred.poll(lifecycle.released)
|
|
128
|
+
const released = Option.isSome(result)
|
|
129
|
+
? yield* Effect.exit(result.value)
|
|
130
|
+
: Exit.void
|
|
131
|
+
const cause = Cause.combine(
|
|
132
|
+
Exit.isFailure(disposed) ? disposed.cause : Cause.empty,
|
|
133
|
+
Exit.isFailure(released) ? released.cause : Cause.empty,
|
|
134
|
+
)
|
|
135
|
+
if (cause.reasons.length > 0)
|
|
136
|
+
return yield* Effect.failCause(cleanupCause(cause))
|
|
137
|
+
})
|
|
138
|
+
|
|
88
139
|
export default Plugin.make({
|
|
89
140
|
name: "remote-server",
|
|
90
|
-
config:
|
|
91
|
-
|
|
141
|
+
config: Schema.Unknown,
|
|
142
|
+
inject: [Plugin.optional(Application)],
|
|
143
|
+
apply: Effect.fnUntraced(function* (input) {
|
|
144
|
+
const application = yield* Effect.serviceOption(Application)
|
|
145
|
+
const config = yield* Schema.decodeUnknownEffect(Configuration.Runner)(
|
|
146
|
+
input,
|
|
147
|
+
).pipe(
|
|
148
|
+
Effect.tapError((error) =>
|
|
149
|
+
Option.isSome(application)
|
|
150
|
+
? application.value.finish(Exit.fail(error))
|
|
151
|
+
: Effect.void,
|
|
152
|
+
),
|
|
153
|
+
)
|
|
154
|
+
const lifecycle = yield* Lifecycle.make
|
|
92
155
|
const encoded = yield* Schema.encodeEffect(Configuration.Runner)(config)
|
|
93
|
-
const
|
|
156
|
+
const assembly = Plugin.make({
|
|
157
|
+
name: "remote-runner-runtime",
|
|
158
|
+
apply: Effect.fnUntraced(function* () {
|
|
159
|
+
yield* Graft.provide(Lifecycle.RunnerLifecycle, lifecycle)
|
|
160
|
+
const fork = yield* Graft.plugin(owner, encoded)
|
|
161
|
+
const fail = yield* boundary("runner")
|
|
162
|
+
yield* follow(fork, fail)
|
|
163
|
+
}),
|
|
164
|
+
})
|
|
165
|
+
const fork = yield* Graft.plugin(assembly, undefined, {
|
|
166
|
+
isolate: [Supervisor, Lifecycle.RunnerLifecycle],
|
|
167
|
+
})
|
|
168
|
+
if (Option.isSome(application)) {
|
|
169
|
+
yield* application.value.onExit(shutdown(fork, lifecycle))
|
|
170
|
+
yield* Plugin.fork(
|
|
171
|
+
Deferred.await(lifecycle.ended).pipe(
|
|
172
|
+
Effect.matchCauseEffect({
|
|
173
|
+
onSuccess: () => application.value.finish(Exit.void),
|
|
174
|
+
onFailure: (cause) =>
|
|
175
|
+
application.value.finish(Exit.failCause(cause)),
|
|
176
|
+
}),
|
|
177
|
+
),
|
|
178
|
+
)
|
|
179
|
+
}
|
|
94
180
|
const fail = yield* boundary("runner")
|
|
95
|
-
yield* follow(fork,
|
|
181
|
+
yield* follow(fork, (cause) =>
|
|
182
|
+
(Option.isSome(application) && !Cause.hasInterruptsOnly(cause)
|
|
183
|
+
? application.value.finish(Exit.failCause(cause))
|
|
184
|
+
: Effect.void
|
|
185
|
+
).pipe(Effect.andThen(fail(cause))),
|
|
186
|
+
)
|
|
96
187
|
}),
|
|
97
188
|
})
|
package/src/runner/stdio.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { Graft, Plugin } from "@graftland/graft"
|
|
2
1
|
import {
|
|
3
2
|
Cause,
|
|
4
3
|
Deferred,
|
|
@@ -10,9 +9,12 @@ import {
|
|
|
10
9
|
Stdio,
|
|
11
10
|
Stream,
|
|
12
11
|
} from "effect"
|
|
13
|
-
|
|
12
|
+
|
|
13
|
+
import { Graft, Plugin } from "@graftland/graft"
|
|
14
|
+
import * as Release from "@graftland/graft/Release"
|
|
15
|
+
|
|
14
16
|
import { TransportError } from "../Errors"
|
|
15
|
-
import
|
|
17
|
+
import { Listener, type Accept } from "../Transport"
|
|
16
18
|
|
|
17
19
|
export const Config = Schema.Struct({ auth: Schema.optionalKey(Schema.Never) })
|
|
18
20
|
export default Plugin.make({
|
|
@@ -30,7 +32,7 @@ export default Plugin.make({
|
|
|
30
32
|
},
|
|
31
33
|
bind: Effect.fnUntraced(function* () {
|
|
32
34
|
const ready = yield* Deferred.make<void>()
|
|
33
|
-
const eof = yield* Deferred.make<void>()
|
|
35
|
+
const eof = yield* Deferred.make<void, TransportError>()
|
|
34
36
|
const channel = {
|
|
35
37
|
input: stdio.stdin.pipe(
|
|
36
38
|
Stream.onExit((exit) =>
|
|
@@ -42,13 +44,16 @@ export default Plugin.make({
|
|
|
42
44
|
TransportError.make({ cause: Cause.fail(error) }),
|
|
43
45
|
),
|
|
44
46
|
),
|
|
45
|
-
output: stdio
|
|
46
|
-
.
|
|
47
|
-
|
|
48
|
-
Sink.mapError((error) =>
|
|
49
|
-
TransportError.make({ cause: Cause.fail(error) }),
|
|
50
|
-
),
|
|
47
|
+
output: stdio.stdout({ endOnDone: false }).pipe(
|
|
48
|
+
Sink.mapError((error) =>
|
|
49
|
+
TransportError.make({ cause: Cause.fail(error) }),
|
|
51
50
|
),
|
|
51
|
+
Sink.onExit((exit) =>
|
|
52
|
+
Exit.isFailure(exit) && !Cause.hasInterruptsOnly(exit.cause)
|
|
53
|
+
? Deferred.failCause(eof, exit.cause)
|
|
54
|
+
: Effect.void,
|
|
55
|
+
),
|
|
56
|
+
),
|
|
52
57
|
}
|
|
53
58
|
return {
|
|
54
59
|
ready: Deferred.await(ready),
|
package/src/runner/unix.ts
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
import { Graft, Plugin } from "@graftland/graft"
|
|
2
|
-
import { ConfigDirectory } from "@graftland/loader"
|
|
3
|
-
import { Cause, Console, Effect, Option, Path, Schema } from "effect"
|
|
4
1
|
// @effect-diagnostics-next-line nodeBuiltinImport:off -- NodeHttpServer takes a factory for an HTTP/1.1 server on the Unix socket
|
|
5
2
|
import { createServer } from "node:http"
|
|
6
|
-
|
|
3
|
+
|
|
4
|
+
import { Cause, Console, Effect, Option, Path, Schema } from "effect"
|
|
5
|
+
|
|
6
|
+
import { Graft, Plugin } from "@graftland/graft"
|
|
7
|
+
import { ConfigDirectory } from "@graftland/loader"
|
|
8
|
+
|
|
7
9
|
import { TransportError } from "../Errors"
|
|
8
10
|
import * as Server from "../internal/websocketServer"
|
|
11
|
+
import { Listener } from "../Transport"
|
|
9
12
|
|
|
10
13
|
export const Config = Schema.Struct({ path: Schema.String })
|
|
11
14
|
const Listening = Schema.fromJsonString(
|
package/src/runner/websocket.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
// @effect-diagnostics-next-line nodeBuiltinImport:off -- NodeHttpServer takes a factory for an HTTP/1.1 upgrade server
|
|
2
|
+
import { createServer } from "node:http"
|
|
3
|
+
import { createSecureServer } from "node:http2"
|
|
4
|
+
|
|
2
5
|
import {
|
|
3
6
|
Cause,
|
|
4
7
|
Console,
|
|
@@ -9,16 +12,15 @@ import {
|
|
|
9
12
|
Schema,
|
|
10
13
|
String,
|
|
11
14
|
} from "effect"
|
|
15
|
+
|
|
16
|
+
import { Graft, Plugin } from "@graftland/graft"
|
|
12
17
|
import { ConfigDirectory } from "@graftland/loader"
|
|
13
|
-
|
|
14
|
-
import { Url, path as upgradePath } from "../internal/websocket"
|
|
15
|
-
import { Listener } from "../Transport"
|
|
18
|
+
|
|
16
19
|
import type { TlsPolicy } from "../Auth"
|
|
17
20
|
import { TransportError } from "../Errors"
|
|
21
|
+
import { properties, path as upgradePath, Url } from "../internal/websocket"
|
|
18
22
|
import * as Server from "../internal/websocketServer"
|
|
19
|
-
import {
|
|
20
|
-
// @effect-diagnostics-next-line nodeBuiltinImport:off -- NodeHttpServer takes a factory for an HTTP/1.1 upgrade server
|
|
21
|
-
import { createServer } from "node:http"
|
|
23
|
+
import { Listener } from "../Transport"
|
|
22
24
|
|
|
23
25
|
const url = (protocol: "ws:" | "wss:") =>
|
|
24
26
|
Url.check(
|
package/dist/Auth-BElTC9_X.js
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { Context } from "effect";
|
|
2
|
-
// packages/remote/src/Auth.ts
|
|
3
|
-
/** Credentials and authenticated identities shared by transport plugins. */
|
|
4
|
-
var Credentials = class extends Context.Service()("@graftland/plugin-remote/Auth/Credentials") {};
|
|
5
|
-
var Authenticator = class extends Context.Service()("@graftland/plugin-remote/Auth/Authenticator") {};
|
|
6
|
-
export { Credentials as n, Authenticator as t };
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { D as Identity } from "./Peer-DXeVrGBh.js";
|
|
2
|
-
import { r as Limits } from "./port--3x2zJ4D.js";
|
|
3
|
-
import { Schema } from "effect";
|
|
4
|
-
// packages/remote/src/internal/runner/Bootstrap.ts
|
|
5
|
-
const Bootstrap = Schema.Struct({
|
|
6
|
-
identity: Identity,
|
|
7
|
-
limits: Limits
|
|
8
|
-
});
|
|
9
|
-
export { Bootstrap as t };
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { Context, Option } from "effect";
|
|
2
|
-
// packages/loader/src/ConfigDirectory.ts
|
|
3
|
-
/** Directory of the supplied configuration path, before following symbolic links. */
|
|
4
|
-
const ConfigDirectory = Context.Reference("@graftland/loader/ConfigDirectory", { defaultValue: Option.none });
|
|
5
|
-
export { ConfigDirectory as t };
|