kourou 1.4.0-dev.4 → 1.5.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/README.md +892 -707
- package/bin/run +10 -24
- package/lib/commands/api-key/check.d.ts +11 -14
- package/lib/commands/api-key/check.js +5 -5
- package/lib/commands/api-key/create.d.ts +14 -17
- package/lib/commands/api-key/create.js +7 -5
- package/lib/commands/api-key/delete.d.ts +12 -14
- package/lib/commands/api-key/delete.js +6 -6
- package/lib/commands/api-key/search.d.ts +12 -15
- package/lib/commands/api-key/search.js +5 -3
- package/lib/commands/app/debug-proxy.d.ts +15 -16
- package/lib/commands/app/debug-proxy.js +7 -7
- package/lib/commands/app/doctor.d.ts +11 -12
- package/lib/commands/app/doctor.js +3 -3
- package/lib/commands/app/scaffold.d.ts +5 -8
- package/lib/commands/app/scaffold.js +8 -9
- package/lib/commands/app/start-services.d.ts +2 -2
- package/lib/commands/app/start-services.js +3 -3
- package/lib/commands/collection/create.d.ts +14 -19
- package/lib/commands/collection/create.js +8 -9
- package/lib/commands/collection/export.d.ts +20 -22
- package/lib/commands/collection/export.js +14 -14
- package/lib/commands/collection/import.d.ts +15 -18
- package/lib/commands/collection/import.js +9 -9
- package/lib/commands/collection/migrate.d.ts +15 -17
- package/lib/commands/collection/migrate.js +12 -9
- package/lib/commands/config/diff.d.ts +5 -6
- package/lib/commands/config/diff.js +11 -9
- package/lib/commands/document/search.d.ts +20 -25
- package/lib/commands/document/search.js +13 -13
- package/lib/commands/es/aliases/cat.d.ts +3 -4
- package/lib/commands/es/aliases/cat.js +4 -4
- package/lib/commands/es/indices/cat.d.ts +3 -4
- package/lib/commands/es/indices/cat.js +4 -4
- package/lib/commands/es/indices/get.d.ts +5 -7
- package/lib/commands/es/indices/get.js +7 -7
- package/lib/commands/es/indices/insert.d.ts +6 -9
- package/lib/commands/es/indices/insert.js +8 -8
- package/lib/commands/es/migrate.d.ts +11 -12
- package/lib/commands/es/migrate.js +26 -15
- package/lib/commands/es/snapshot/create-repository.d.ts +6 -8
- package/lib/commands/es/snapshot/create-repository.js +12 -10
- package/lib/commands/es/snapshot/create.d.ts +6 -8
- package/lib/commands/es/snapshot/create.js +11 -8
- package/lib/commands/es/snapshot/list.d.ts +4 -7
- package/lib/commands/es/snapshot/list.js +7 -8
- package/lib/commands/es/snapshot/restore.d.ts +6 -8
- package/lib/commands/es/snapshot/restore.js +11 -8
- package/lib/commands/file/decrypt.d.ts +5 -8
- package/lib/commands/file/decrypt.js +7 -7
- package/lib/commands/file/encrypt.d.ts +5 -8
- package/lib/commands/file/encrypt.js +7 -5
- package/lib/commands/file/test.d.ts +3 -6
- package/lib/commands/file/test.js +5 -5
- package/lib/commands/import.d.ts +13 -16
- package/lib/commands/import.js +8 -9
- package/lib/commands/index/export.d.ts +17 -20
- package/lib/commands/index/export.js +12 -11
- package/lib/commands/index/import.d.ts +14 -17
- package/lib/commands/index/import.js +11 -8
- package/lib/commands/instance/kill.d.ts +2 -3
- package/lib/commands/instance/kill.js +6 -7
- package/lib/commands/instance/logs.d.ts +2 -3
- package/lib/commands/instance/logs.js +3 -3
- package/lib/commands/instance/spawn.d.ts +3 -4
- package/lib/commands/instance/spawn.js +7 -8
- package/lib/commands/paas/login.d.ts +4 -5
- package/lib/commands/paas/login.js +13 -8
- package/lib/commands/profile/export.d.ts +10 -11
- package/lib/commands/profile/export.js +3 -3
- package/lib/commands/profile/import.d.ts +11 -14
- package/lib/commands/profile/import.js +5 -3
- package/lib/commands/realtime/subscribe.d.ts +19 -24
- package/lib/commands/realtime/subscribe.js +12 -12
- package/lib/commands/redis/list-keys.d.ts +14 -17
- package/lib/commands/redis/list-keys.js +8 -9
- package/lib/commands/role/export.d.ts +10 -11
- package/lib/commands/role/export.js +3 -3
- package/lib/commands/role/import.d.ts +12 -15
- package/lib/commands/role/import.js +6 -4
- package/lib/commands/sdk/execute.d.ts +15 -18
- package/lib/commands/sdk/execute.js +9 -10
- package/lib/commands/sdk/query.d.ts +20 -23
- package/lib/commands/sdk/query.js +14 -15
- package/lib/commands/user/export-mappings.d.ts +10 -11
- package/lib/commands/user/export-mappings.js +3 -3
- package/lib/commands/user/export.d.ts +14 -15
- package/lib/commands/user/export.js +7 -7
- package/lib/commands/user/import-mappings.d.ts +11 -14
- package/lib/commands/user/import-mappings.js +5 -3
- package/lib/commands/user/import.d.ts +11 -14
- package/lib/commands/user/import.js +5 -3
- package/lib/commands/vault/add.d.ts +5 -6
- package/lib/commands/vault/add.js +9 -11
- package/lib/commands/vault/decrypt.d.ts +5 -8
- package/lib/commands/vault/decrypt.js +8 -9
- package/lib/commands/vault/encrypt.d.ts +5 -8
- package/lib/commands/vault/encrypt.js +8 -9
- package/lib/commands/vault/show.d.ts +5 -11
- package/lib/commands/vault/show.js +7 -8
- package/lib/commands/vault/test.d.ts +3 -6
- package/lib/commands/vault/test.js +6 -7
- package/lib/common.d.ts +1 -1
- package/lib/common.js +3 -3
- package/lib/help.d.ts +16 -0
- package/lib/help.js +31 -0
- package/lib/hooks/command_not_found/api-action.d.ts +1 -1
- package/lib/hooks/command_not_found/api-action.js +8 -8
- package/lib/index.d.ts +1 -1
- package/lib/index.js +2 -2
- package/lib/support/dump-collection.js +2 -2
- package/lib/support/kuzzle.d.ts +8 -9
- package/lib/support/kuzzle.js +9 -9
- package/lib/support/progressBar.d.ts +10 -0
- package/lib/support/progressBar.js +15 -0
- package/package.json +13 -12
package/bin/run
CHANGED
|
@@ -1,31 +1,17 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
const
|
|
3
|
+
const oclif = require('@oclif/core')
|
|
4
4
|
|
|
5
|
-
const Help_showHelp = Help.prototype.showHelp;
|
|
6
5
|
/**
|
|
7
|
-
*
|
|
8
|
-
*
|
|
6
|
+
* oclif v1 accepted -v as an alias for --version, @oclif/core does not, and a
|
|
7
|
+
* script calling `kourou -v` would print nothing at all rather than fail.
|
|
8
|
+
*
|
|
9
|
+
* Only the first token is rewritten: a command name never starts with a dash,
|
|
10
|
+
* so this cannot swallow the -v that instance:spawn uses for its own version
|
|
11
|
+
* flag.
|
|
9
12
|
*/
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
try {
|
|
14
|
-
return Help_showHelp.call(context, ...args);
|
|
15
|
-
}
|
|
16
|
-
catch (error) {
|
|
17
|
-
error.message += `
|
|
18
|
-
|
|
19
|
-
If you tried to execute and API action you can see
|
|
20
|
-
available options by displaying the "sdk:query" command help:
|
|
21
|
-
- kourou sdk:query --help`;
|
|
22
|
-
|
|
23
|
-
throw error;
|
|
24
|
-
}
|
|
13
|
+
if (process.argv[2] === '-v') {
|
|
14
|
+
process.argv[2] = '--version'
|
|
25
15
|
}
|
|
26
16
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
require('@oclif/command').run()
|
|
30
|
-
.then(require('@oclif/command/flush'))
|
|
31
|
-
.catch(require('@oclif/errors/handle'))
|
|
17
|
+
oclif.run().then(oclif.flush).catch(oclif.handle)
|
|
@@ -1,23 +1,20 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
declare class ApiKeyCheck extends Kommand {
|
|
4
3
|
static description: string;
|
|
5
4
|
static flags: {
|
|
6
|
-
host:
|
|
7
|
-
port:
|
|
8
|
-
ssl: import("@oclif/
|
|
9
|
-
username:
|
|
10
|
-
password:
|
|
11
|
-
protocol:
|
|
12
|
-
as:
|
|
13
|
-
"api-key":
|
|
14
|
-
help: import("@oclif/
|
|
5
|
+
host: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
6
|
+
port: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
7
|
+
ssl: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
username: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
password: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
10
|
+
protocol: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
|
+
as: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
12
|
+
"api-key": import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
13
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
15
14
|
};
|
|
16
15
|
static args: {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
required: boolean;
|
|
20
|
-
}[];
|
|
16
|
+
token: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
17
|
+
};
|
|
21
18
|
static examples: string[];
|
|
22
19
|
runSafe(): Promise<void>;
|
|
23
20
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const
|
|
3
|
+
const core_1 = require("@oclif/core");
|
|
4
4
|
const common_1 = require("../../common");
|
|
5
5
|
const kuzzle_1 = require("../../support/kuzzle");
|
|
6
6
|
class ApiKeyCheck extends common_1.Kommand {
|
|
@@ -15,9 +15,9 @@ class ApiKeyCheck extends common_1.Kommand {
|
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
17
|
ApiKeyCheck.description = "Checks an API key validity";
|
|
18
|
-
ApiKeyCheck.flags = Object.assign({ help:
|
|
19
|
-
ApiKeyCheck.args =
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
ApiKeyCheck.flags = Object.assign({ help: core_1.Flags.help() }, kuzzle_1.kuzzleFlags);
|
|
19
|
+
ApiKeyCheck.args = {
|
|
20
|
+
token: core_1.Args.string({ description: "API key token", required: true }),
|
|
21
|
+
};
|
|
22
22
|
ApiKeyCheck.examples = ["kourou api-key:check eyJhbG...QxfQrc"];
|
|
23
23
|
exports.default = ApiKeyCheck;
|
|
@@ -1,26 +1,23 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
declare class ApiKeyCreate extends Kommand {
|
|
4
3
|
static description: string;
|
|
5
4
|
static flags: {
|
|
6
|
-
host:
|
|
7
|
-
port:
|
|
8
|
-
ssl: import("@oclif/
|
|
9
|
-
username:
|
|
10
|
-
password:
|
|
11
|
-
protocol:
|
|
12
|
-
as:
|
|
13
|
-
"api-key":
|
|
14
|
-
help: import("@oclif/
|
|
15
|
-
description:
|
|
16
|
-
id:
|
|
17
|
-
expire:
|
|
5
|
+
host: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
6
|
+
port: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
7
|
+
ssl: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
username: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
password: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
10
|
+
protocol: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
|
+
as: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
12
|
+
"api-key": import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
13
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
14
|
+
description: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
15
|
+
id: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
16
|
+
expire: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
18
17
|
};
|
|
19
18
|
static args: {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
required: boolean;
|
|
23
|
-
}[];
|
|
19
|
+
user: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
20
|
+
};
|
|
24
21
|
runSafe(): Promise<void>;
|
|
25
22
|
}
|
|
26
23
|
export default ApiKeyCreate;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const
|
|
3
|
+
const core_1 = require("@oclif/core");
|
|
4
4
|
const common_1 = require("../../common");
|
|
5
5
|
const kuzzle_1 = require("../../support/kuzzle");
|
|
6
6
|
class ApiKeyCreate extends common_1.Kommand {
|
|
@@ -14,15 +14,17 @@ class ApiKeyCreate extends common_1.Kommand {
|
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
16
|
ApiKeyCreate.description = "Creates a new API Key for a user";
|
|
17
|
-
ApiKeyCreate.flags = Object.assign({ help:
|
|
17
|
+
ApiKeyCreate.flags = Object.assign({ help: core_1.Flags.help(), description: core_1.Flags.string({
|
|
18
18
|
char: "d",
|
|
19
19
|
description: "API Key description",
|
|
20
20
|
required: true,
|
|
21
|
-
}), id:
|
|
21
|
+
}), id: core_1.Flags.string({
|
|
22
22
|
description: "API Key unique ID",
|
|
23
|
-
}), expire:
|
|
23
|
+
}), expire: core_1.Flags.string({
|
|
24
24
|
description: "API Key validity",
|
|
25
25
|
default: "-1",
|
|
26
26
|
}) }, kuzzle_1.kuzzleFlags);
|
|
27
|
-
ApiKeyCreate.args =
|
|
27
|
+
ApiKeyCreate.args = {
|
|
28
|
+
user: core_1.Args.string({ description: "User kuid", required: true }),
|
|
29
|
+
};
|
|
28
30
|
exports.default = ApiKeyCreate;
|
|
@@ -1,23 +1,21 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
declare class ApiKeyDelete extends Kommand {
|
|
4
3
|
static description: string;
|
|
5
4
|
static flags: {
|
|
6
|
-
host:
|
|
7
|
-
port:
|
|
8
|
-
ssl: import("@oclif/
|
|
9
|
-
username:
|
|
10
|
-
password:
|
|
11
|
-
protocol:
|
|
12
|
-
as:
|
|
13
|
-
"api-key":
|
|
14
|
-
help: import("@oclif/
|
|
5
|
+
host: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
6
|
+
port: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
7
|
+
ssl: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
username: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
password: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
10
|
+
protocol: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
|
+
as: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
12
|
+
"api-key": import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
13
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
15
14
|
};
|
|
16
15
|
static args: {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
}[];
|
|
16
|
+
user: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
17
|
+
id: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
18
|
+
};
|
|
21
19
|
static examples: string[];
|
|
22
20
|
runSafe(): Promise<void>;
|
|
23
21
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const
|
|
3
|
+
const core_1 = require("@oclif/core");
|
|
4
4
|
const common_1 = require("../../common");
|
|
5
5
|
const kuzzle_1 = require("../../support/kuzzle");
|
|
6
6
|
class ApiKeyDelete extends common_1.Kommand {
|
|
@@ -10,10 +10,10 @@ class ApiKeyDelete extends common_1.Kommand {
|
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
ApiKeyDelete.description = "Deletes an API key.";
|
|
13
|
-
ApiKeyDelete.flags = Object.assign({ help:
|
|
14
|
-
ApiKeyDelete.args =
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
13
|
+
ApiKeyDelete.flags = Object.assign({ help: core_1.Flags.help() }, kuzzle_1.kuzzleFlags);
|
|
14
|
+
ApiKeyDelete.args = {
|
|
15
|
+
user: core_1.Args.string({ description: "User kuid", required: true }),
|
|
16
|
+
id: core_1.Args.string({ description: "API Key unique ID", required: true }),
|
|
17
|
+
};
|
|
18
18
|
ApiKeyDelete.examples = ["kourou vault:delete sigfox-gateway 1k-BF3EBjsXdvA2PR8x"];
|
|
19
19
|
exports.default = ApiKeyDelete;
|
|
@@ -1,24 +1,21 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
declare class ApiKeySearch extends Kommand {
|
|
4
3
|
static description: string;
|
|
5
4
|
static flags: {
|
|
6
|
-
host:
|
|
7
|
-
port:
|
|
8
|
-
ssl: import("@oclif/
|
|
9
|
-
username:
|
|
10
|
-
password:
|
|
11
|
-
protocol:
|
|
12
|
-
as:
|
|
13
|
-
"api-key":
|
|
14
|
-
help: import("@oclif/
|
|
15
|
-
filter:
|
|
5
|
+
host: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
6
|
+
port: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
7
|
+
ssl: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
username: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
password: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
10
|
+
protocol: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
|
+
as: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
12
|
+
"api-key": import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
13
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
14
|
+
filter: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
16
15
|
};
|
|
17
16
|
static args: {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
required: boolean;
|
|
21
|
-
}[];
|
|
17
|
+
user: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
18
|
+
};
|
|
22
19
|
runSafe(): Promise<void>;
|
|
23
20
|
}
|
|
24
21
|
export default ApiKeySearch;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const
|
|
3
|
+
const core_1 = require("@oclif/core");
|
|
4
4
|
const common_1 = require("../../common");
|
|
5
5
|
const kuzzle_1 = require("../../support/kuzzle");
|
|
6
6
|
class ApiKeySearch extends common_1.Kommand {
|
|
@@ -30,8 +30,10 @@ class ApiKeySearch extends common_1.Kommand {
|
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
32
|
ApiKeySearch.description = "Lists a user's API Keys.";
|
|
33
|
-
ApiKeySearch.flags = Object.assign({ help:
|
|
33
|
+
ApiKeySearch.flags = Object.assign({ help: core_1.Flags.help(), filter: core_1.Flags.string({
|
|
34
34
|
description: "Filter to match the API Key descriptions",
|
|
35
35
|
}) }, kuzzle_1.kuzzleFlags);
|
|
36
|
-
ApiKeySearch.args =
|
|
36
|
+
ApiKeySearch.args = {
|
|
37
|
+
user: core_1.Args.string({ description: "User kuid", required: true }),
|
|
38
|
+
};
|
|
37
39
|
exports.default = ApiKeySearch;
|
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
export default class DebugProxy extends Kommand {
|
|
4
3
|
static description: string;
|
|
5
4
|
static flags: {
|
|
6
|
-
host:
|
|
7
|
-
port:
|
|
8
|
-
ssl: import("@oclif/
|
|
9
|
-
username:
|
|
10
|
-
password:
|
|
11
|
-
protocol:
|
|
12
|
-
as:
|
|
13
|
-
"api-key":
|
|
14
|
-
help: import("@oclif/
|
|
15
|
-
forwardPort: import("@oclif/
|
|
16
|
-
ttl:
|
|
17
|
-
keepAuth: import("@oclif/
|
|
18
|
-
noAutoEnableDebugger: import("@oclif/
|
|
19
|
-
showDebuggerEvents: import("@oclif/
|
|
20
|
-
showDebuggerPayloads: import("@oclif/
|
|
5
|
+
host: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
6
|
+
port: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
7
|
+
ssl: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
username: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
password: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
10
|
+
protocol: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
|
+
as: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
12
|
+
"api-key": import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
13
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
14
|
+
forwardPort: import("@oclif/core/lib/interfaces").OptionFlag<number, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
15
|
+
ttl: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
16
|
+
keepAuth: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
17
|
+
noAutoEnableDebugger: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
18
|
+
showDebuggerEvents: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
19
|
+
showDebuggerPayloads: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
21
20
|
};
|
|
22
21
|
static sdkOptions: {
|
|
23
22
|
protocol: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
|
-
const
|
|
4
|
+
const core_1 = require("@oclif/core");
|
|
5
5
|
const common_1 = require("../../common");
|
|
6
6
|
const kuzzle_1 = require("../../support/kuzzle");
|
|
7
7
|
const http_1 = tslib_1.__importDefault(require("http"));
|
|
@@ -160,22 +160,22 @@ class DebugProxy extends common_1.Kommand {
|
|
|
160
160
|
}
|
|
161
161
|
}
|
|
162
162
|
DebugProxy.description = "Create a Proxy Server that allows Chrome to debug Kuzzle remotely using the DebugController";
|
|
163
|
-
DebugProxy.flags = Object.assign({ help:
|
|
163
|
+
DebugProxy.flags = Object.assign({ help: core_1.Flags.help(), forwardPort: core_1.Flags.integer({
|
|
164
164
|
description: "Port of the forwarding server",
|
|
165
165
|
default: 9222,
|
|
166
|
-
}), ttl:
|
|
166
|
+
}), ttl: core_1.Flags.string({
|
|
167
167
|
description: "Kuzzle login TTL",
|
|
168
168
|
default: "1h",
|
|
169
|
-
}), keepAuth:
|
|
169
|
+
}), keepAuth: core_1.Flags.boolean({
|
|
170
170
|
description: "Keep the user authenticated",
|
|
171
171
|
default: false,
|
|
172
|
-
}), noAutoEnableDebugger:
|
|
172
|
+
}), noAutoEnableDebugger: core_1.Flags.boolean({
|
|
173
173
|
description: "True if Kourou should not enable and disable the Debugger automatically before and after usage",
|
|
174
174
|
default: false,
|
|
175
|
-
}), showDebuggerEvents:
|
|
175
|
+
}), showDebuggerEvents: core_1.Flags.boolean({
|
|
176
176
|
description: "Verbose mode to display events sent to the Chrome Debugger",
|
|
177
177
|
default: false,
|
|
178
|
-
}), showDebuggerPayloads:
|
|
178
|
+
}), showDebuggerPayloads: core_1.Flags.boolean({
|
|
179
179
|
description: "Verbose mode to display payloads sent by and to the Chrome Debugger",
|
|
180
180
|
default: false,
|
|
181
181
|
}) }, kuzzle_1.kuzzleFlags);
|
|
@@ -1,20 +1,19 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
export default class AppDoctor extends Kommand {
|
|
4
3
|
static description: string;
|
|
5
4
|
static flags: {
|
|
6
|
-
host:
|
|
7
|
-
port:
|
|
8
|
-
ssl: import("@oclif/
|
|
9
|
-
username:
|
|
10
|
-
password:
|
|
11
|
-
protocol:
|
|
12
|
-
as:
|
|
13
|
-
"api-key":
|
|
14
|
-
help: import("@oclif/
|
|
15
|
-
elasticsearch:
|
|
5
|
+
host: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
6
|
+
port: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
7
|
+
ssl: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
username: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
password: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
10
|
+
protocol: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
|
+
as: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
12
|
+
"api-key": import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
13
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
14
|
+
elasticsearch: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
16
15
|
};
|
|
17
|
-
static args:
|
|
16
|
+
static args: {};
|
|
18
17
|
static readStdin: boolean;
|
|
19
18
|
ELK_MAX_VERSION: number;
|
|
20
19
|
NODEJS_MAX_VERSION: number;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
|
-
const
|
|
4
|
+
const core_1 = require("@oclif/core");
|
|
5
5
|
const common_1 = require("../../common");
|
|
6
6
|
const kuzzle_1 = require("../../support/kuzzle");
|
|
7
7
|
const sdk_es7_1 = require("sdk-es7");
|
|
@@ -186,10 +186,10 @@ class AppDoctor extends common_1.Kommand {
|
|
|
186
186
|
}
|
|
187
187
|
}
|
|
188
188
|
AppDoctor.description = "Analyze a Kuzzle application";
|
|
189
|
-
AppDoctor.flags = Object.assign({ help:
|
|
189
|
+
AppDoctor.flags = Object.assign({ help: core_1.Flags.help(), elasticsearch: core_1.Flags.string({
|
|
190
190
|
description: "Elasticsearch server URL",
|
|
191
191
|
default: "http://localhost:9200",
|
|
192
192
|
}) }, kuzzle_1.kuzzleFlags);
|
|
193
|
-
AppDoctor.args =
|
|
193
|
+
AppDoctor.args = {};
|
|
194
194
|
AppDoctor.readStdin = true;
|
|
195
195
|
exports.default = AppDoctor;
|
|
@@ -1,19 +1,16 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
export default class AppScaffold extends Kommand {
|
|
4
3
|
templatesDir: string;
|
|
5
4
|
static initSdk: boolean;
|
|
6
5
|
static description: string;
|
|
7
6
|
static flags: {
|
|
8
|
-
help: import("@oclif/
|
|
9
|
-
flavor:
|
|
10
|
-
token:
|
|
7
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
8
|
+
flavor: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
token: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
10
|
};
|
|
12
11
|
static args: {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
required: boolean;
|
|
16
|
-
}[];
|
|
12
|
+
destination: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
13
|
+
};
|
|
17
14
|
runSafe(): Promise<void>;
|
|
18
15
|
getRepo(flavor: string): "template-kuzzle-project" | "template-kiotp-project" | "template-hypervision-project";
|
|
19
16
|
checkDestination(destination: string): Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
|
-
const
|
|
4
|
+
const core_1 = require("@oclif/core");
|
|
5
5
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
6
6
|
const listr_1 = tslib_1.__importDefault(require("listr"));
|
|
7
7
|
const common_1 = require("../../common");
|
|
@@ -155,21 +155,20 @@ class AppScaffold extends common_1.Kommand {
|
|
|
155
155
|
AppScaffold.initSdk = false;
|
|
156
156
|
AppScaffold.description = "Scaffolds a new Kuzzle application";
|
|
157
157
|
AppScaffold.flags = {
|
|
158
|
-
help:
|
|
159
|
-
flavor:
|
|
158
|
+
help: core_1.Flags.help(),
|
|
159
|
+
flavor: core_1.Flags.string({
|
|
160
160
|
default: "generic",
|
|
161
161
|
description: `Template flavor ("generic", "iot", "hypervision").`,
|
|
162
162
|
}),
|
|
163
|
-
token:
|
|
163
|
+
token: core_1.Flags.string({
|
|
164
164
|
description: `GitHub token used to clone private template repositories.
|
|
165
165
|
Defaults to the GITHUB_TOKEN environment variable, then to the GitHub CLI credentials.`,
|
|
166
166
|
}),
|
|
167
167
|
};
|
|
168
|
-
AppScaffold.args =
|
|
169
|
-
{
|
|
170
|
-
name: "destination",
|
|
168
|
+
AppScaffold.args = {
|
|
169
|
+
destination: core_1.Args.string({
|
|
171
170
|
description: "Directory to scaffold the app",
|
|
172
171
|
required: true,
|
|
173
|
-
},
|
|
174
|
-
|
|
172
|
+
}),
|
|
173
|
+
};
|
|
175
174
|
exports.default = AppScaffold;
|
|
@@ -3,8 +3,8 @@ export default class AppStartServices extends Kommand {
|
|
|
3
3
|
static initSdk: boolean;
|
|
4
4
|
static description: string;
|
|
5
5
|
static flags: {
|
|
6
|
-
help: import("@oclif/
|
|
7
|
-
check: import("@oclif/
|
|
6
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
7
|
+
check: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
8
|
};
|
|
9
9
|
runSafe(): Promise<void>;
|
|
10
10
|
}
|
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
4
|
const fs_1 = require("fs");
|
|
5
5
|
const path_1 = tslib_1.__importDefault(require("path"));
|
|
6
|
-
const
|
|
6
|
+
const core_1 = require("@oclif/core");
|
|
7
7
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
8
8
|
const emoji_1 = require("../../support/emoji");
|
|
9
9
|
const common_1 = require("../../common");
|
|
@@ -58,8 +58,8 @@ class AppStartServices extends common_1.Kommand {
|
|
|
58
58
|
AppStartServices.initSdk = false;
|
|
59
59
|
AppStartServices.description = "Starts Kuzzle services (Elasticsearch and Redis)";
|
|
60
60
|
AppStartServices.flags = {
|
|
61
|
-
help:
|
|
62
|
-
check:
|
|
61
|
+
help: core_1.Flags.help(),
|
|
62
|
+
check: core_1.Flags.boolean({
|
|
63
63
|
description: "Check prerequisite before running services",
|
|
64
64
|
default: false,
|
|
65
65
|
}),
|
|
@@ -1,27 +1,22 @@
|
|
|
1
|
-
import { flags } from "@oclif/command";
|
|
2
1
|
import { Kommand } from "../../common";
|
|
3
2
|
export default class CollectionCreate extends Kommand {
|
|
4
3
|
static description: string;
|
|
5
4
|
static flags: {
|
|
6
|
-
host:
|
|
7
|
-
port:
|
|
8
|
-
ssl: import("@oclif/
|
|
9
|
-
username:
|
|
10
|
-
password:
|
|
11
|
-
protocol:
|
|
12
|
-
as:
|
|
13
|
-
"api-key":
|
|
14
|
-
help: import("@oclif/
|
|
5
|
+
host: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
6
|
+
port: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
7
|
+
ssl: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
username: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
9
|
+
password: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
10
|
+
protocol: import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
11
|
+
as: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
12
|
+
"api-key": import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
|
|
13
|
+
help: import("@oclif/core/lib/interfaces").BooleanFlag<void>;
|
|
14
|
+
};
|
|
15
|
+
static args: {
|
|
16
|
+
index: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
17
|
+
collection: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
18
|
+
body: import("@oclif/core/lib/interfaces").Arg<string | undefined, Record<string, unknown>>;
|
|
15
19
|
};
|
|
16
|
-
static args: ({
|
|
17
|
-
name: string;
|
|
18
|
-
description: string;
|
|
19
|
-
required: boolean;
|
|
20
|
-
} | {
|
|
21
|
-
name: string;
|
|
22
|
-
description: string;
|
|
23
|
-
required?: undefined;
|
|
24
|
-
})[];
|
|
25
20
|
static readStdin: boolean;
|
|
26
21
|
runSafe(): Promise<void>;
|
|
27
22
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const
|
|
3
|
+
const core_1 = require("@oclif/core");
|
|
4
4
|
const common_1 = require("../../common");
|
|
5
5
|
const kuzzle_1 = require("../../support/kuzzle");
|
|
6
6
|
class CollectionCreate extends common_1.Kommand {
|
|
@@ -15,14 +15,13 @@ class CollectionCreate extends common_1.Kommand {
|
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
17
|
CollectionCreate.description = "Creates a collection";
|
|
18
|
-
CollectionCreate.flags = Object.assign({ help:
|
|
19
|
-
CollectionCreate.args =
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
{
|
|
23
|
-
name: "body",
|
|
18
|
+
CollectionCreate.flags = Object.assign({ help: core_1.Flags.help() }, kuzzle_1.kuzzleFlags);
|
|
19
|
+
CollectionCreate.args = {
|
|
20
|
+
index: core_1.Args.string({ description: "Index name", required: true }),
|
|
21
|
+
collection: core_1.Args.string({ description: "Collection name", required: true }),
|
|
22
|
+
body: core_1.Args.string({
|
|
24
23
|
description: "Collection mappings and settings in JS or JSON format. Will be read from STDIN if available",
|
|
25
|
-
},
|
|
26
|
-
|
|
24
|
+
}),
|
|
25
|
+
};
|
|
27
26
|
CollectionCreate.readStdin = true;
|
|
28
27
|
exports.default = CollectionCreate;
|