@boole-digital/cli 0.2.4 → 0.2.5
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/dist/index.js +18 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -356,8 +356,23 @@ var BooleApi = class {
|
|
|
356
356
|
method: "POST",
|
|
357
357
|
body: JSON.stringify({ accessCode: (accessCode || "").trim() })
|
|
358
358
|
});
|
|
359
|
-
const
|
|
360
|
-
|
|
359
|
+
const cand = [
|
|
360
|
+
body?.data?.droplet_password,
|
|
361
|
+
body?.data?.password,
|
|
362
|
+
body?.data?.ssh_password,
|
|
363
|
+
body?.data?.sshPassword,
|
|
364
|
+
body?.droplet_password,
|
|
365
|
+
body?.password,
|
|
366
|
+
body?.ssh_password,
|
|
367
|
+
body?.sshPassword,
|
|
368
|
+
body?.result?.password
|
|
369
|
+
];
|
|
370
|
+
const pw = cand.find((v) => typeof v === "string" && v.length > 0);
|
|
371
|
+
if (!pw) {
|
|
372
|
+
throw new Error(
|
|
373
|
+
"SSH password not present. topKeys=" + JSON.stringify(Object.keys(body || {})) + " dataKeys=" + JSON.stringify(Object.keys(body?.data || {}))
|
|
374
|
+
);
|
|
375
|
+
}
|
|
361
376
|
return String(pw);
|
|
362
377
|
}
|
|
363
378
|
// ---- talk to the gateway on the box (via the ownership-checked proxy) ---
|
|
@@ -751,7 +766,7 @@ function init(opts = {}) {
|
|
|
751
766
|
}
|
|
752
767
|
|
|
753
768
|
// src/index.ts
|
|
754
|
-
var VERSION = "0.2.
|
|
769
|
+
var VERSION = "0.2.5";
|
|
755
770
|
function parse(argv) {
|
|
756
771
|
const _ = [];
|
|
757
772
|
const flags = {};
|
package/package.json
CHANGED