multicloud_rule_manager 1.0.31 → 1.0.32
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/commands/deploy.js +4 -6
- package/package.json +1 -1
package/commands/deploy.js
CHANGED
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
import fs from "fs";
|
|
2
2
|
import path from "path";
|
|
3
|
+
import { getAlias } from "../utils/aliasManager.js";
|
|
4
|
+
|
|
3
5
|
export default {
|
|
4
|
-
command: "
|
|
5
|
-
describe: "
|
|
6
|
-
builder: {
|
|
7
|
-
output: { type: "string", default: "retrieve.json", describe: "File di output" }
|
|
8
|
-
},
|
|
6
|
+
command: "deploy <alias>",
|
|
7
|
+
describe: "Deploy dei file rules su API",
|
|
9
8
|
handler: async (argv) => {
|
|
10
9
|
try {
|
|
11
10
|
console.log("🔹 Recupero credenziali per alias:", argv.alias);
|
|
12
11
|
const cred = getAlias(argv.alias);
|
|
13
|
-
|
|
14
12
|
// --- PRIMA CHIAMATA: token ---
|
|
15
13
|
console.log("🔹 Inizio richiesta token...");
|
|
16
14
|
const loginResp = await fetch(`https://login-eon-no-prod.bit2win.cloud/auth/realms/${cred.realm}/protocol/openid-connect/token`, {
|