@celljs/ta-gateway 4.30.0 → 4.32.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.
|
@@ -7,5 +7,7 @@ export interface GatewayCliOptions {
|
|
|
7
7
|
version?: string;
|
|
8
8
|
}
|
|
9
9
|
export declare namespace GatewayCli {
|
|
10
|
+
/** What `ta gateway --help` prints. */
|
|
11
|
+
const help = "Usage: ta gateway [--host <host>] [--port <port>] [--dir <dir>]\n ta gateway link <account> [--name <name>] [--dir <dir>]\n\nOne sign-in for many people, each with a Ta of their own: an account that signs in is a tenant, whose\nTa runs in a sandbox of its own (a container per tenant by default), or in a Ta service of the user's.\nThe web client is served here; each browser's connection goes to the Ta of its tenant. Stops on SIGINT\nor SIGTERM.\n\n --host Address to listen on. Default: 127.0.0.1\n --port Port to listen on. Default: 4100, or PORT\n --dir Its configuration and data. Default: TA_GATEWAY_DIR, else ~/.ta/gateway\n --config Where sandboxes.json and models.json are, when not in --dir (a directory mounted read-only).\n Default: TA_GATEWAY_CONFIG\n\nAccounts sign in with the providers of the environment (TA_GITHUB_*, TA_GOOGLE_*, TA_WECHAT_*,\nTA_OIDC_*, as for ta serve) when TA_ALLOWED_USERS lets them in; TA_GATEWAY_ADMINS are let in too and\nmanage the others. \"ta gateway link <account>\" prints a link that signs in as the account once, within\na day, and lets it in: for someone without a provider of accounts (user:alice), or before one is set up.\n\nThe sandboxes are those of sandboxes.json in the directory, written as models.json is for models:\n { \"default\": \"docker\",\n \"providers\": { \"docker\": { \"type\": \"docker\", \"image\": \"ta:latest\", \"memory\": \"4g\" } } }\nTypes: docker, command (shell commands for any platform), local (no isolation: tests), ta (a Ta service\nthat runs), module (a file whose default export makes a provider). See the README of @celljs/ta-gateway.\n\nAt /.well-known/ta it tells the deployment it is part of: TA_DEPLOYMENT_NAME, its own address and the\nrelay (TA_RELAY_URL), which every sandbox is given too; /healthz and /readyz are for probes.\n";
|
|
10
12
|
function run(argv: string[], options: GatewayCliOptions): Promise<void>;
|
|
11
13
|
}
|
package/esm/node/gateway-cli.js
CHANGED
|
@@ -23,8 +23,9 @@ TA_OIDC_*, as for ta serve) when TA_ALLOWED_USERS lets them in; TA_GATEWAY_ADMIN
|
|
|
23
23
|
manage the others. "ta gateway link <account>" prints a link that signs in as the account once, within
|
|
24
24
|
a day, and lets it in: for someone without a provider of accounts (user:alice), or before one is set up.
|
|
25
25
|
|
|
26
|
-
The sandboxes are those of sandboxes.json in the directory, as
|
|
27
|
-
{ "default": "docker",
|
|
26
|
+
The sandboxes are those of sandboxes.json in the directory, written as models.json is for models:
|
|
27
|
+
{ "default": "docker",
|
|
28
|
+
"providers": { "docker": { "type": "docker", "image": "ta:latest", "memory": "4g" } } }
|
|
28
29
|
Types: docker, command (shell commands for any platform), local (no isolation: tests), ta (a Ta service
|
|
29
30
|
that runs), module (a file whose default export makes a provider). See the README of @celljs/ta-gateway.
|
|
30
31
|
|
|
@@ -33,6 +34,8 @@ relay (TA_RELAY_URL), which every sandbox is given too; /healthz and /readyz are
|
|
|
33
34
|
`;
|
|
34
35
|
export var GatewayCli;
|
|
35
36
|
(function (GatewayCli) {
|
|
37
|
+
/** What `ta gateway --help` prints. */
|
|
38
|
+
GatewayCli.help = HELP;
|
|
36
39
|
async function run(argv, options) {
|
|
37
40
|
var _a, _b, _c, _d, _e;
|
|
38
41
|
const { values, positionals } = parseArgs({
|
|
@@ -7,6 +7,8 @@ export interface GatewayCliOptions {
|
|
|
7
7
|
version?: string;
|
|
8
8
|
}
|
|
9
9
|
export declare namespace GatewayCli {
|
|
10
|
+
/** What `ta gateway --help` prints. */
|
|
11
|
+
const help = "Usage: ta gateway [--host <host>] [--port <port>] [--dir <dir>]\n ta gateway link <account> [--name <name>] [--dir <dir>]\n\nOne sign-in for many people, each with a Ta of their own: an account that signs in is a tenant, whose\nTa runs in a sandbox of its own (a container per tenant by default), or in a Ta service of the user's.\nThe web client is served here; each browser's connection goes to the Ta of its tenant. Stops on SIGINT\nor SIGTERM.\n\n --host Address to listen on. Default: 127.0.0.1\n --port Port to listen on. Default: 4100, or PORT\n --dir Its configuration and data. Default: TA_GATEWAY_DIR, else ~/.ta/gateway\n --config Where sandboxes.json and models.json are, when not in --dir (a directory mounted read-only).\n Default: TA_GATEWAY_CONFIG\n\nAccounts sign in with the providers of the environment (TA_GITHUB_*, TA_GOOGLE_*, TA_WECHAT_*,\nTA_OIDC_*, as for ta serve) when TA_ALLOWED_USERS lets them in; TA_GATEWAY_ADMINS are let in too and\nmanage the others. \"ta gateway link <account>\" prints a link that signs in as the account once, within\na day, and lets it in: for someone without a provider of accounts (user:alice), or before one is set up.\n\nThe sandboxes are those of sandboxes.json in the directory, written as models.json is for models:\n { \"default\": \"docker\",\n \"providers\": { \"docker\": { \"type\": \"docker\", \"image\": \"ta:latest\", \"memory\": \"4g\" } } }\nTypes: docker, command (shell commands for any platform), local (no isolation: tests), ta (a Ta service\nthat runs), module (a file whose default export makes a provider). See the README of @celljs/ta-gateway.\n\nAt /.well-known/ta it tells the deployment it is part of: TA_DEPLOYMENT_NAME, its own address and the\nrelay (TA_RELAY_URL), which every sandbox is given too; /healthz and /readyz are for probes.\n";
|
|
10
12
|
function run(argv: string[], options: GatewayCliOptions): Promise<void>;
|
|
11
13
|
}
|
|
12
14
|
//# sourceMappingURL=gateway-cli.d.ts.map
|
package/lib/node/gateway-cli.js
CHANGED
|
@@ -26,8 +26,9 @@ TA_OIDC_*, as for ta serve) when TA_ALLOWED_USERS lets them in; TA_GATEWAY_ADMIN
|
|
|
26
26
|
manage the others. "ta gateway link <account>" prints a link that signs in as the account once, within
|
|
27
27
|
a day, and lets it in: for someone without a provider of accounts (user:alice), or before one is set up.
|
|
28
28
|
|
|
29
|
-
The sandboxes are those of sandboxes.json in the directory, as
|
|
30
|
-
{ "default": "docker",
|
|
29
|
+
The sandboxes are those of sandboxes.json in the directory, written as models.json is for models:
|
|
30
|
+
{ "default": "docker",
|
|
31
|
+
"providers": { "docker": { "type": "docker", "image": "ta:latest", "memory": "4g" } } }
|
|
31
32
|
Types: docker, command (shell commands for any platform), local (no isolation: tests), ta (a Ta service
|
|
32
33
|
that runs), module (a file whose default export makes a provider). See the README of @celljs/ta-gateway.
|
|
33
34
|
|
|
@@ -36,6 +37,8 @@ relay (TA_RELAY_URL), which every sandbox is given too; /healthz and /readyz are
|
|
|
36
37
|
`;
|
|
37
38
|
var GatewayCli;
|
|
38
39
|
(function (GatewayCli) {
|
|
40
|
+
/** What `ta gateway --help` prints. */
|
|
41
|
+
GatewayCli.help = HELP;
|
|
39
42
|
async function run(argv, options) {
|
|
40
43
|
var _a, _b, _c, _d, _e;
|
|
41
44
|
const { values, positionals } = (0, node_util_1.parseArgs)({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@celljs/ta-gateway",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.32.0",
|
|
4
4
|
"description": "ta gateway: one Ta per account, each in a sandbox of its own, behind one sign-in",
|
|
5
5
|
"homepage": "https://github.com/cellbang/ta",
|
|
6
6
|
"bugs": {
|
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
"watch": "tsc -b -w --preserveWatchOutput"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@celljs/rpc": "4.
|
|
33
|
-
"@celljs/ta-host": "4.
|
|
34
|
-
"@celljs/ta-protocol": "4.
|
|
35
|
-
"@celljs/ta-relay": "4.
|
|
32
|
+
"@celljs/rpc": "4.32.0",
|
|
33
|
+
"@celljs/ta-host": "4.32.0",
|
|
34
|
+
"@celljs/ta-protocol": "4.32.0",
|
|
35
|
+
"@celljs/ta-relay": "4.32.0"
|
|
36
36
|
},
|
|
37
37
|
"publishConfig": {
|
|
38
38
|
"access": "public"
|