biz-a-cli 2.3.78-15202 → 2.3.78-15207
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/bin/hubEvent.js +4 -1
- package/engine/domain/system.js +11 -7
- package/package.json +1 -1
package/bin/hubEvent.js
CHANGED
|
@@ -347,7 +347,10 @@ const handleCliCommand = async (data, cb, argv) => {
|
|
|
347
347
|
);
|
|
348
348
|
}
|
|
349
349
|
|
|
350
|
-
const result = await engineModule[methodName](
|
|
350
|
+
const result = await engineModule[methodName](
|
|
351
|
+
data.payload,
|
|
352
|
+
argv,
|
|
353
|
+
);
|
|
351
354
|
|
|
352
355
|
cb(null, { success: true, data: result });
|
|
353
356
|
break;
|
package/engine/domain/system.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const publishApp = async (data) => {
|
|
1
|
+
export const publishApp = async (data, argv = {}) => {
|
|
2
2
|
try {
|
|
3
3
|
process.env.BIZA_APP_SKIP_PARSE = "1";
|
|
4
4
|
const { addApp } = await import("../../bin/app.js");
|
|
@@ -46,10 +46,14 @@ export const publishApp = async (data) => {
|
|
|
46
46
|
const response = await addApp({
|
|
47
47
|
workingDir: params.workingDir || process.cwd(),
|
|
48
48
|
verbose: !!params.verbose,
|
|
49
|
-
server: params.server || "http://localhost",
|
|
50
|
-
apiPort: toNumber(params.apiPort, 212),
|
|
51
|
-
dbIndex: toNumber(params.dbIndex, 2),
|
|
52
|
-
sub:
|
|
49
|
+
server: argv.server || params.server || "http://localhost",
|
|
50
|
+
apiPort: toNumber(argv.port, toNumber(params.apiPort, 212)),
|
|
51
|
+
dbIndex: toNumber(argv.dbindex, toNumber(params.dbIndex, 2)),
|
|
52
|
+
sub:
|
|
53
|
+
argv.subdomain ||
|
|
54
|
+
params.sub ||
|
|
55
|
+
params.subdomain ||
|
|
56
|
+
data?.domainId,
|
|
53
57
|
files: params.files || params.fileList,
|
|
54
58
|
body: publishPayload,
|
|
55
59
|
});
|
|
@@ -65,6 +69,6 @@ export const publishApp = async (data) => {
|
|
|
65
69
|
}
|
|
66
70
|
};
|
|
67
71
|
|
|
68
|
-
export function publish(payload) {
|
|
69
|
-
return publishApp(payload);
|
|
72
|
+
export function publish(payload, argv = {}) {
|
|
73
|
+
return publishApp(payload, argv);
|
|
70
74
|
}
|