@probelabs/visor 0.1.96 → 0.1.98
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 +20 -19
- package/defaults/.visor.yaml +3 -2
- package/dist/{168.index.js → 136.index.js} +5 -5
- package/dist/{272.index.js → 146.index.js} +5 -5
- package/dist/{13.index.js → 160.index.js} +5 -5
- package/dist/{421.index.js → 179.index.js} +3 -3
- package/dist/{85.index.js → 191.index.js} +5 -5
- package/dist/{544.index.js → 384.index.js} +3 -3
- package/dist/{861.index.js → 405.index.js} +3 -3
- package/dist/{320.index.js → 42.index.js} +3 -3
- package/dist/448.index.js +48 -0
- package/dist/{878.index.js → 491.index.js} +5 -5
- package/dist/663.index.js +321 -0
- package/dist/69.index.js +38 -0
- package/dist/{54.index.js → 760.index.js} +5 -5
- package/dist/80.index.js +263 -0
- package/dist/886.index.js +81 -0
- package/dist/917.index.js +82 -0
- package/dist/955.index.js +82 -0
- package/dist/ai-review-service.d.ts +2 -3
- package/dist/ai-review-service.d.ts.map +1 -1
- package/dist/check-execution-engine.d.ts.map +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/config.d.ts +5 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/defaults/.visor.yaml +3 -2
- package/dist/generated/config-schema.d.ts +24 -3
- package/dist/generated/config-schema.d.ts.map +1 -1
- package/dist/generated/config-schema.json +28 -3
- package/dist/index.js +198171 -161819
- package/dist/proto/protoc-gen-validate/LICENSE +202 -0
- package/dist/proto/protoc-gen-validate/validate/validate.proto +797 -0
- package/dist/proto/xds/LICENSE +201 -0
- package/dist/proto/xds/xds/data/orca/v3/orca_load_report.proto +58 -0
- package/dist/proto/xds/xds/service/orca/v3/orca.proto +36 -0
- package/dist/protoc-gen-validate/LICENSE +202 -0
- package/dist/protoc-gen-validate/validate/validate.proto +797 -0
- package/dist/providers/check-provider-registry.d.ts.map +1 -1
- package/dist/providers/index.d.ts +1 -0
- package/dist/providers/index.d.ts.map +1 -1
- package/dist/providers/mcp-check-provider.d.ts +102 -0
- package/dist/providers/mcp-check-provider.d.ts.map +1 -0
- package/dist/sdk/check-execution-engine-W5FLIWZL.mjs +11 -0
- package/dist/sdk/chunk-IG3BFIIN.mjs +174 -0
- package/dist/sdk/chunk-IG3BFIIN.mjs.map +1 -0
- package/dist/sdk/{chunk-Q4S5A5TO.mjs → chunk-POYXI3MQ.mjs} +610 -21
- package/dist/sdk/chunk-POYXI3MQ.mjs.map +1 -0
- package/dist/sdk/chunk-YXOWIDEF.mjs +60 -0
- package/dist/sdk/chunk-YXOWIDEF.mjs.map +1 -0
- package/dist/sdk/{mermaid-telemetry-LZGDD35I.mjs → mermaid-telemetry-4DUEYCLE.mjs} +2 -2
- package/dist/sdk/sdk.d.mts +16 -3
- package/dist/sdk/sdk.d.ts +16 -3
- package/dist/sdk/sdk.js +994 -1513
- package/dist/sdk/sdk.js.map +1 -1
- package/dist/sdk/sdk.mjs +70 -13
- package/dist/sdk/sdk.mjs.map +1 -1
- package/dist/sdk/{tracer-init-O7RLXMJ3.mjs → tracer-init-RJGAIOBP.mjs} +2 -2
- package/dist/session-registry.d.ts +2 -3
- package/dist/session-registry.d.ts.map +1 -1
- package/dist/traces/run-2025-10-19T19-05-29-328Z.ndjson +40 -0
- package/dist/traces/run-2025-10-19T19-05-42-253Z.ndjson +40 -0
- package/dist/traces/run-2025-10-19T19-05-42-805Z.ndjson +40 -0
- package/dist/traces/run-2025-10-19T19-05-43-323Z.ndjson +40 -0
- package/dist/traces/run-2025-10-19T19-05-43-841Z.ndjson +12 -0
- package/dist/types/config.d.ts +16 -3
- package/dist/types/config.d.ts.map +1 -1
- package/dist/utils/config-loader.d.ts +5 -0
- package/dist/utils/config-loader.d.ts.map +1 -1
- package/dist/utils/tracer-init.d.ts +3 -4
- package/dist/utils/tracer-init.d.ts.map +1 -1
- package/dist/xds/LICENSE +201 -0
- package/dist/xds/xds/data/orca/v3/orca_load_report.proto +58 -0
- package/dist/xds/xds/service/orca/v3/orca.proto +36 -0
- package/package.json +15 -8
- package/dist/sdk/check-execution-engine-NMPXJ7FQ.mjs +0 -11
- package/dist/sdk/chunk-KVHVCGY6.mjs +0 -103
- package/dist/sdk/chunk-KVHVCGY6.mjs.map +0 -1
- package/dist/sdk/chunk-Q4S5A5TO.mjs.map +0 -1
- package/dist/sdk/chunk-TWJKAYT6.mjs +0 -1124
- package/dist/sdk/chunk-TWJKAYT6.mjs.map +0 -1
- /package/dist/{traces/run-2025-10-18T20-24-27-886Z.ndjson → output/traces/run-2025-10-19T19-05-29-328Z.ndjson} +0 -0
- /package/dist/{traces/run-2025-10-18T20-24-38-817Z.ndjson → output/traces/run-2025-10-19T19-05-42-253Z.ndjson} +0 -0
- /package/dist/{traces/run-2025-10-18T20-24-39-361Z.ndjson → output/traces/run-2025-10-19T19-05-42-805Z.ndjson} +0 -0
- /package/dist/{traces/run-2025-10-18T20-24-39-852Z.ndjson → output/traces/run-2025-10-19T19-05-43-323Z.ndjson} +0 -0
- /package/dist/{traces/run-2025-10-18T20-24-40-335Z.ndjson → output/traces/run-2025-10-19T19-05-43-841Z.ndjson} +0 -0
- /package/dist/sdk/{check-execution-engine-NMPXJ7FQ.mjs.map → check-execution-engine-W5FLIWZL.mjs.map} +0 -0
- /package/dist/sdk/{mermaid-telemetry-LZGDD35I.mjs.map → mermaid-telemetry-4DUEYCLE.mjs.map} +0 -0
- /package/dist/sdk/{tracer-init-O7RLXMJ3.mjs.map → tracer-init-RJGAIOBP.mjs.map} +0 -0
package/README.md
CHANGED
|
@@ -56,7 +56,7 @@ jobs:
|
|
|
56
56
|
|
|
57
57
|
```yaml
|
|
58
58
|
version: "1.0"
|
|
59
|
-
checks
|
|
59
|
+
steps: # or 'checks' (legacy, both work identically)
|
|
60
60
|
security:
|
|
61
61
|
type: ai
|
|
62
62
|
schema: code-review
|
|
@@ -130,7 +130,7 @@ Additional guides:
|
|
|
130
130
|
- Schema – JSON shape checks return (e.g., `code-review`).
|
|
131
131
|
- Template – renders results (tables/markdown).
|
|
132
132
|
- Group – which comment a check is posted into.
|
|
133
|
-
- Provider – how a check runs (`ai`, `http`, `http_client`, `command`, `log`, `github`, `claude-code`).
|
|
133
|
+
- Provider – how a check runs (`ai`, `mcp`, `http`, `http_client`, `command`, `log`, `github`, `claude-code`).
|
|
134
134
|
- Dependencies – `depends_on` controls order; independents run in parallel.
|
|
135
135
|
- Tags – label checks (`fast`, `local`, `comprehensive`) and filter with `--tags`.
|
|
136
136
|
- Events – PRs, issues, `/review` comments, webhooks, or cron schedules.
|
|
@@ -188,11 +188,11 @@ Visor is a general SDLC automation framework:
|
|
|
188
188
|
- Config‑first: One `.visor.yaml` defines checks, prompts, schemas, and templates — no hidden logic.
|
|
189
189
|
- Structured outputs: JSON Schema validation drives deterministic rendering, annotations, and SARIF.
|
|
190
190
|
- Orchestrated pipelines: Dependencies, parallelism, and tag‑based profiles; run in Actions or any CI.
|
|
191
|
-
- Multi‑provider AI: Google Gemini, Anthropic Claude, OpenAI, AWS Bedrock — plus MCP tools and Claude Code SDK.
|
|
191
|
+
- Multi‑provider AI: Google Gemini, Anthropic Claude, OpenAI, AWS Bedrock — plus MCP tools, standalone MCP provider, and Claude Code SDK.
|
|
192
192
|
- Author permissions: Built-in functions to customize workflows based on contributor trust level (owner, member, collaborator, etc).
|
|
193
193
|
- Assistants & commands: `/review` to rerun checks, `/visor …` for Q&A, predictable comment groups.
|
|
194
194
|
- HTTP & schedules: Receive webhooks, call external APIs, and run cron‑scheduled audits and reports.
|
|
195
|
-
- Extensible providers: `ai`, `http`, `http_client`, `log`, `command`, `github`, `claude-code` — or add your own.
|
|
195
|
+
- Extensible providers: `ai`, `mcp`, `http`, `http_client`, `log`, `command`, `github`, `claude-code` — or add your own.
|
|
196
196
|
- Security by default: GitHub App support, scoped tokens, remote‑extends allowlist, opt‑in network usage.
|
|
197
197
|
- Observability & control: JSON/SARIF outputs, fail‑fast and timeouts, parallelism and cost control.
|
|
198
198
|
|
|
@@ -221,7 +221,7 @@ Run subsets of checks (e.g., `local`, `fast`, `security`) and select them per en
|
|
|
221
221
|
|
|
222
222
|
Example:
|
|
223
223
|
```yaml
|
|
224
|
-
|
|
224
|
+
steps:
|
|
225
225
|
security-quick:
|
|
226
226
|
type: ai
|
|
227
227
|
prompt: "Quick security scan"
|
|
@@ -253,7 +253,7 @@ Learn more: [docs/commands.md](docs/commands.md)
|
|
|
253
253
|
Customize workflows based on PR author's permission level using built-in functions in JavaScript expressions:
|
|
254
254
|
|
|
255
255
|
```yaml
|
|
256
|
-
|
|
256
|
+
steps:
|
|
257
257
|
# Run security scan only for external contributors
|
|
258
258
|
security-scan:
|
|
259
259
|
type: command
|
|
@@ -391,7 +391,7 @@ Define `depends_on` to enforce order; independent checks run in parallel.
|
|
|
391
391
|
|
|
392
392
|
Example:
|
|
393
393
|
```yaml
|
|
394
|
-
|
|
394
|
+
steps:
|
|
395
395
|
security: { type: ai }
|
|
396
396
|
performance:{ type: ai, depends_on: [security] }
|
|
397
397
|
```
|
|
@@ -416,7 +416,7 @@ Example (retry + goto on failure):
|
|
|
416
416
|
version: "2.0"
|
|
417
417
|
routing:
|
|
418
418
|
max_loops: 5
|
|
419
|
-
|
|
419
|
+
steps:
|
|
420
420
|
setup: { type: command, exec: "echo setup" }
|
|
421
421
|
build:
|
|
422
422
|
type: command
|
|
@@ -431,7 +431,7 @@ checks:
|
|
|
431
431
|
|
|
432
432
|
Example (on_success jump‑back once):
|
|
433
433
|
```yaml
|
|
434
|
-
|
|
434
|
+
steps:
|
|
435
435
|
unit: { type: command, exec: "echo unit" }
|
|
436
436
|
build:
|
|
437
437
|
type: command
|
|
@@ -453,7 +453,7 @@ Use the Claude Code SDK as a provider for deeper analysis.
|
|
|
453
453
|
|
|
454
454
|
Example:
|
|
455
455
|
```yaml
|
|
456
|
-
|
|
456
|
+
steps:
|
|
457
457
|
claude-review:
|
|
458
458
|
type: claude-code
|
|
459
459
|
prompt: "Analyze code complexity"
|
|
@@ -471,7 +471,7 @@ Reuse conversation context between dependent AI checks for smarter follow‑ups.
|
|
|
471
471
|
|
|
472
472
|
Example:
|
|
473
473
|
```yaml
|
|
474
|
-
|
|
474
|
+
steps:
|
|
475
475
|
security: { type: ai }
|
|
476
476
|
remediation:
|
|
477
477
|
type: ai
|
|
@@ -492,7 +492,7 @@ Schemas validate outputs; templates render GitHub‑friendly comments.
|
|
|
492
492
|
|
|
493
493
|
Example:
|
|
494
494
|
```yaml
|
|
495
|
-
|
|
495
|
+
steps:
|
|
496
496
|
security:
|
|
497
497
|
type: ai
|
|
498
498
|
schema: code-review
|
|
@@ -507,7 +507,7 @@ Write prompts inline or in files; Liquid variables provide PR context.
|
|
|
507
507
|
|
|
508
508
|
Example:
|
|
509
509
|
```yaml
|
|
510
|
-
|
|
510
|
+
steps:
|
|
511
511
|
overview:
|
|
512
512
|
type: ai
|
|
513
513
|
prompt: ./prompts/overview.liquid
|
|
@@ -566,7 +566,7 @@ Comprehensive debugging tools help troubleshoot configurations and data flows:
|
|
|
566
566
|
|
|
567
567
|
**Use `log()` in JavaScript expressions:**
|
|
568
568
|
```yaml
|
|
569
|
-
|
|
569
|
+
steps:
|
|
570
570
|
conditional-check:
|
|
571
571
|
if: |
|
|
572
572
|
log("Outputs:", outputs);
|
|
@@ -579,7 +579,7 @@ checks:
|
|
|
579
579
|
|
|
580
580
|
**Use `json` filter in Liquid templates:**
|
|
581
581
|
```yaml
|
|
582
|
-
|
|
582
|
+
steps:
|
|
583
583
|
debug-check:
|
|
584
584
|
type: logger
|
|
585
585
|
message: |
|
|
@@ -614,7 +614,7 @@ Receive webhooks, call APIs, and schedule checks.
|
|
|
614
614
|
Examples:
|
|
615
615
|
```yaml
|
|
616
616
|
http_server: { enabled: true, port: 8080 }
|
|
617
|
-
|
|
617
|
+
steps:
|
|
618
618
|
nightly: { type: ai, schedule: "0 2 * * *" }
|
|
619
619
|
```
|
|
620
620
|
|
|
@@ -622,10 +622,11 @@ Learn more: [docs/http.md](docs/http.md)
|
|
|
622
622
|
|
|
623
623
|
## 🔧 Pluggable Architecture
|
|
624
624
|
|
|
625
|
-
Mix providers (`ai`, `http`, `http_client`, `log`, `command`, `claude-code`) or add your own.
|
|
625
|
+
Mix providers (`ai`, `mcp`, `http`, `http_client`, `log`, `command`, `github`, `claude-code`) or add your own.
|
|
626
626
|
|
|
627
627
|
- **Command Provider**: Execute shell commands with templating and security - [docs/command-provider.md](docs/command-provider.md)
|
|
628
|
-
- **MCP
|
|
628
|
+
- **MCP Provider**: Call MCP tools directly via stdio, SSE, or HTTP transports - [docs/mcp-provider.md](docs/mcp-provider.md)
|
|
629
|
+
- **MCP Tools for AI**: Enhance AI providers with MCP context - [docs/mcp.md](docs/mcp.md)
|
|
629
630
|
- **Custom Providers**: Build your own providers - [docs/pluggable.md](docs/pluggable.md)
|
|
630
631
|
|
|
631
632
|
## 🎯 GitHub Action Reference
|
|
@@ -678,7 +679,7 @@ Use the native GitHub provider for safe labels and comments without invoking the
|
|
|
678
679
|
Example — apply overview‑derived labels to a PR:
|
|
679
680
|
|
|
680
681
|
```yaml
|
|
681
|
-
|
|
682
|
+
steps:
|
|
682
683
|
apply-overview-labels:
|
|
683
684
|
type: github
|
|
684
685
|
op: labels.add
|
package/defaults/.visor.yaml
CHANGED
|
@@ -7,13 +7,14 @@ version: "1.0"
|
|
|
7
7
|
# Global AI provider settings - users should configure their preferred provider
|
|
8
8
|
# For CI testing, use --provider mock CLI flag instead
|
|
9
9
|
|
|
10
|
-
# Run up to 4
|
|
10
|
+
# Run up to 4 steps in parallel for faster execution
|
|
11
11
|
max_parallelism: 4
|
|
12
12
|
|
|
13
13
|
# Global fail condition - fail if critical or error severity issues are found
|
|
14
14
|
fail_if: "output.issues && output.issues.some(i => i.severity === 'critical' || i.severity === 'error')"
|
|
15
15
|
|
|
16
|
-
checks
|
|
16
|
+
# Workflow steps (formerly 'checks' - both keys are supported for backward compatibility)
|
|
17
|
+
steps:
|
|
17
18
|
# AI-powered release notes generation - manual execution only for release workflows
|
|
18
19
|
release-notes:
|
|
19
20
|
type: ai
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
exports.id =
|
|
3
|
-
exports.ids = [
|
|
2
|
+
exports.id = 136;
|
|
3
|
+
exports.ids = [136];
|
|
4
4
|
exports.modules = {
|
|
5
5
|
|
|
6
|
-
/***/
|
|
6
|
+
/***/ 95023:
|
|
7
7
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
8
8
|
|
|
9
9
|
|
|
@@ -31,7 +31,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
31
31
|
|
|
32
32
|
/***/ }),
|
|
33
33
|
|
|
34
|
-
/***/
|
|
34
|
+
/***/ 43136:
|
|
35
35
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
36
36
|
|
|
37
37
|
|
|
@@ -52,7 +52,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
52
52
|
*/
|
|
53
53
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
54
54
|
exports.getMachineId = void 0;
|
|
55
|
-
const execAsync_1 = __webpack_require__(
|
|
55
|
+
const execAsync_1 = __webpack_require__(95023);
|
|
56
56
|
const api_1 = __webpack_require__(63914);
|
|
57
57
|
async function getMachineId() {
|
|
58
58
|
try {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
exports.id =
|
|
3
|
-
exports.ids = [
|
|
2
|
+
exports.id = 146;
|
|
3
|
+
exports.ids = [146];
|
|
4
4
|
exports.modules = {
|
|
5
5
|
|
|
6
|
-
/***/
|
|
6
|
+
/***/ 67049:
|
|
7
7
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
8
8
|
|
|
9
9
|
|
|
@@ -31,7 +31,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
31
31
|
|
|
32
32
|
/***/ }),
|
|
33
33
|
|
|
34
|
-
/***/
|
|
34
|
+
/***/ 29146:
|
|
35
35
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
36
36
|
|
|
37
37
|
|
|
@@ -52,7 +52,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
52
52
|
*/
|
|
53
53
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
54
54
|
exports.getMachineId = void 0;
|
|
55
|
-
const execAsync_1 = __webpack_require__(
|
|
55
|
+
const execAsync_1 = __webpack_require__(67049);
|
|
56
56
|
const api_1 = __webpack_require__(63914);
|
|
57
57
|
async function getMachineId() {
|
|
58
58
|
try {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
exports.id =
|
|
3
|
-
exports.ids = [
|
|
2
|
+
exports.id = 160;
|
|
3
|
+
exports.ids = [160];
|
|
4
4
|
exports.modules = {
|
|
5
5
|
|
|
6
|
-
/***/
|
|
6
|
+
/***/ 66272:
|
|
7
7
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
8
8
|
|
|
9
9
|
|
|
@@ -31,7 +31,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
31
31
|
|
|
32
32
|
/***/ }),
|
|
33
33
|
|
|
34
|
-
/***/
|
|
34
|
+
/***/ 51160:
|
|
35
35
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
36
36
|
|
|
37
37
|
|
|
@@ -53,7 +53,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
53
53
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
54
54
|
exports.getMachineId = void 0;
|
|
55
55
|
const process = __webpack_require__(932);
|
|
56
|
-
const execAsync_1 = __webpack_require__(
|
|
56
|
+
const execAsync_1 = __webpack_require__(66272);
|
|
57
57
|
const api_1 = __webpack_require__(63914);
|
|
58
58
|
async function getMachineId() {
|
|
59
59
|
const args = 'QUERY HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Cryptography /v MachineGuid';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
exports.id =
|
|
3
|
-
exports.ids = [
|
|
2
|
+
exports.id = 191;
|
|
3
|
+
exports.ids = [191];
|
|
4
4
|
exports.modules = {
|
|
5
5
|
|
|
6
|
-
/***/
|
|
6
|
+
/***/ 67049:
|
|
7
7
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
8
8
|
|
|
9
9
|
|
|
@@ -31,7 +31,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
31
31
|
|
|
32
32
|
/***/ }),
|
|
33
33
|
|
|
34
|
-
/***/
|
|
34
|
+
/***/ 53191:
|
|
35
35
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
36
36
|
|
|
37
37
|
|
|
@@ -53,7 +53,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
53
53
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
54
54
|
exports.getMachineId = void 0;
|
|
55
55
|
const process = __webpack_require__(932);
|
|
56
|
-
const execAsync_1 = __webpack_require__(
|
|
56
|
+
const execAsync_1 = __webpack_require__(67049);
|
|
57
57
|
const api_1 = __webpack_require__(63914);
|
|
58
58
|
async function getMachineId() {
|
|
59
59
|
const args = 'QUERY HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Cryptography /v MachineGuid';
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
exports.id = 448;
|
|
3
|
+
exports.ids = [448];
|
|
4
|
+
exports.modules = {
|
|
5
|
+
|
|
6
|
+
/***/ 26448:
|
|
7
|
+
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
11
|
+
exports.getMachineId = void 0;
|
|
12
|
+
/*
|
|
13
|
+
* Copyright The OpenTelemetry Authors
|
|
14
|
+
*
|
|
15
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
16
|
+
* you may not use this file except in compliance with the License.
|
|
17
|
+
* You may obtain a copy of the License at
|
|
18
|
+
*
|
|
19
|
+
* https://www.apache.org/licenses/LICENSE-2.0
|
|
20
|
+
*
|
|
21
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
22
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
23
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
24
|
+
* See the License for the specific language governing permissions and
|
|
25
|
+
* limitations under the License.
|
|
26
|
+
*/
|
|
27
|
+
const fs_1 = __webpack_require__(79896);
|
|
28
|
+
const api_1 = __webpack_require__(63914);
|
|
29
|
+
async function getMachineId() {
|
|
30
|
+
const paths = ['/etc/machine-id', '/var/lib/dbus/machine-id'];
|
|
31
|
+
for (const path of paths) {
|
|
32
|
+
try {
|
|
33
|
+
const result = await fs_1.promises.readFile(path, { encoding: 'utf8' });
|
|
34
|
+
return result.trim();
|
|
35
|
+
}
|
|
36
|
+
catch (e) {
|
|
37
|
+
api_1.diag.debug(`error reading machine id: ${e}`);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
return undefined;
|
|
41
|
+
}
|
|
42
|
+
exports.getMachineId = getMachineId;
|
|
43
|
+
//# sourceMappingURL=getMachineId-linux.js.map
|
|
44
|
+
|
|
45
|
+
/***/ })
|
|
46
|
+
|
|
47
|
+
};
|
|
48
|
+
;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
exports.id =
|
|
3
|
-
exports.ids = [
|
|
2
|
+
exports.id = 491;
|
|
3
|
+
exports.ids = [491];
|
|
4
4
|
exports.modules = {
|
|
5
5
|
|
|
6
|
-
/***/
|
|
6
|
+
/***/ 66272:
|
|
7
7
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
8
8
|
|
|
9
9
|
|
|
@@ -31,7 +31,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
31
31
|
|
|
32
32
|
/***/ }),
|
|
33
33
|
|
|
34
|
-
/***/
|
|
34
|
+
/***/ 94491:
|
|
35
35
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
36
36
|
|
|
37
37
|
|
|
@@ -53,7 +53,7 @@ exports.execAsync = util.promisify(child_process.exec);
|
|
|
53
53
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
54
54
|
exports.getMachineId = void 0;
|
|
55
55
|
const fs_1 = __webpack_require__(79896);
|
|
56
|
-
const execAsync_1 = __webpack_require__(
|
|
56
|
+
const execAsync_1 = __webpack_require__(66272);
|
|
57
57
|
const api_1 = __webpack_require__(63914);
|
|
58
58
|
async function getMachineId() {
|
|
59
59
|
try {
|