@basaltkit/deploy 0.4.1 → 0.5.0
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 +276 -23
- package/dist/answers.d.ts +70 -0
- package/dist/answers.js +196 -0
- package/dist/apache.js +11 -2
- package/dist/audit.d.ts +20 -0
- package/dist/audit.js +26 -0
- package/dist/backup.d.ts +17 -1
- package/dist/backup.js +49 -1
- package/dist/bin.js +9 -1
- package/dist/bootstrap.d.ts +68 -18
- package/dist/bootstrap.js +177 -45
- package/dist/caddy.js +2 -1
- package/dist/check.js +18 -5
- package/dist/checks.js +1 -1
- package/dist/cli.d.ts +22 -1
- package/dist/cli.js +498 -57
- package/dist/compose.d.ts +1 -1
- package/dist/compose.js +6 -1
- package/dist/config.d.ts +25 -2
- package/dist/config.js +65 -3
- package/dist/context.d.ts +43 -13
- package/dist/context.js +50 -7
- package/dist/detach.d.ts +23 -0
- package/dist/detach.js +105 -0
- package/dist/env-step.d.ts +16 -1
- package/dist/env-step.js +58 -5
- package/dist/events.d.ts +168 -0
- package/dist/events.js +477 -0
- package/dist/host.d.ts +171 -7
- package/dist/host.js +302 -41
- package/dist/index.d.ts +10 -5
- package/dist/index.js +7 -3
- package/dist/init.d.ts +2 -0
- package/dist/init.js +2 -1
- package/dist/install-plan.d.ts +40 -0
- package/dist/install-plan.js +433 -0
- package/dist/json-host.d.ts +32 -0
- package/dist/json-host.js +106 -0
- package/dist/lock.d.ts +45 -0
- package/dist/lock.js +128 -0
- package/dist/pipeline.d.ts +51 -3
- package/dist/pipeline.js +339 -173
- package/dist/protocol.d.ts +364 -0
- package/dist/protocol.js +134 -0
- package/dist/runs.d.ts +75 -0
- package/dist/runs.js +287 -0
- package/dist/state.d.ts +26 -13
- package/dist/state.js +68 -4
- package/dist/trust.d.ts +63 -0
- package/dist/trust.js +159 -0
- package/dist/version.d.ts +2 -0
- package/dist/version.js +10 -0
- package/package.json +5 -1
package/dist/cli.d.ts
CHANGED
|
@@ -2,7 +2,28 @@ import { type DeployConfig } from './config.js';
|
|
|
2
2
|
import { type DeployContext } from './context.js';
|
|
3
3
|
import { type Host } from './host.js';
|
|
4
4
|
export declare const USAGE: string;
|
|
5
|
+
/**
|
|
6
|
+
* `basalt-deploy ui` (RFC 0009 §3.4): a hint, nothing else. The UI is a
|
|
7
|
+
* separate package that runs on the operator's machine and drives this CLI
|
|
8
|
+
* over ssh; this package gains no listener and no dependency for it.
|
|
9
|
+
*/
|
|
10
|
+
export declare const UI_HINT = "The deploy UI runs on YOUR machine, never on the server: it listens on\n127.0.0.1 only and drives this server over your own ssh, as the app user.\n\nOn your machine (not here, and not in the app's package.json \u2014 the deploy\ninstalls devDependencies on the server):\n\n npx @basaltkit/deploy-ui@<exact version>\n\nIt opens your browser. Add a target (ssh destination and this checkout's\ndirectory), check the connection, plan, deploy. See the @basaltkit/deploy-ui\nREADME for its security model.\n";
|
|
11
|
+
/** Another deploy holds the lock: nothing was done. */
|
|
12
|
+
export declare const EXIT_LOCKED = 3;
|
|
13
|
+
/** A signal stopped the command at a step boundary. */
|
|
14
|
+
export declare const EXIT_ABORTED = 130;
|
|
5
15
|
/** Loads deploy.config.ts with the app's own tsx when it has one, else Node's type stripping. */
|
|
6
16
|
export declare function loadConfig(dir: string, file: string): Promise<DeployConfig>;
|
|
7
17
|
export declare function createContext(host: Host, dir: string, config: DeployConfig): Promise<DeployContext>;
|
|
8
|
-
|
|
18
|
+
/** The process's own stdin and stdout, which the machine protocol uses (RFC 0008 §3.3). */
|
|
19
|
+
export interface CliIO {
|
|
20
|
+
/** stdout as it was before anything replaced `process.stdout.write`. */
|
|
21
|
+
write(text: string): void;
|
|
22
|
+
stdin(): AsyncIterable<string | Uint8Array>;
|
|
23
|
+
/** Turns writes to `process.stdout` and `process.stderr` into `sink` calls, until the returned function is called. */
|
|
24
|
+
capture(sink: (text: string) => void): () => void;
|
|
25
|
+
/** One plain line on stderr: the event writer itself failed. */
|
|
26
|
+
stderr(text: string): void;
|
|
27
|
+
}
|
|
28
|
+
export declare function processIO(stream?: NodeJS.WritableStream, input?: AsyncIterable<string | Uint8Array>, errors?: NodeJS.WritableStream): CliIO;
|
|
29
|
+
export declare function main(argv: string[], host?: Host, cwd?: string, io?: CliIO): Promise<number>;
|