@cedarjs/cli 3.0.0-canary.13640 → 3.0.0-rc.112
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.
|
@@ -5,8 +5,10 @@ import { Listr } from "listr2";
|
|
|
5
5
|
import * as toml from "smol-toml";
|
|
6
6
|
import { env as envInterpolation } from "string-env-interpolation";
|
|
7
7
|
import { titleCase } from "title-case";
|
|
8
|
+
import { recordTelemetryAttributes } from "@cedarjs/cli-helpers";
|
|
8
9
|
import c from "../../../lib/colors.js";
|
|
9
10
|
import { getPaths } from "../../../lib/index.js";
|
|
11
|
+
import { SshExecutor } from "./SshExecutor.js";
|
|
10
12
|
const CONFIG_FILENAME = "deploy.toml";
|
|
11
13
|
const SYMLINK_FLAGS = "-nsf";
|
|
12
14
|
const CURRENT_RELEASE_SYMLINK_NAME = "current";
|
|
@@ -491,7 +493,20 @@ const commands = (yargs, ssh) => {
|
|
|
491
493
|
return servers;
|
|
492
494
|
};
|
|
493
495
|
const handler = async (yargs) => {
|
|
494
|
-
|
|
496
|
+
recordTelemetryAttributes({
|
|
497
|
+
command: "deploy baremetal",
|
|
498
|
+
firstRun: yargs.firstRun,
|
|
499
|
+
df: yargs.df,
|
|
500
|
+
update: yargs.update,
|
|
501
|
+
install: yargs.install,
|
|
502
|
+
migrate: yargs.migrate,
|
|
503
|
+
build: yargs.build,
|
|
504
|
+
restart: yargs.restart,
|
|
505
|
+
cleanup: yargs.cleanup,
|
|
506
|
+
maintenance: yargs.maintenance,
|
|
507
|
+
rollback: yargs.rollback,
|
|
508
|
+
verbose: yargs.verbose
|
|
509
|
+
});
|
|
495
510
|
const tomlPath = path.join(getPaths().base, "deploy.toml");
|
|
496
511
|
const ecosystemPath = path.join(getPaths().base, "ecosystem.config.js");
|
|
497
512
|
if (!fs.existsSync(tomlPath) || !fs.existsSync(ecosystemPath)) {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { terminalLink } from "termi-link";
|
|
2
|
-
import { recordTelemetryAttributes } from "@cedarjs/cli-helpers";
|
|
3
2
|
const command = "baremetal [environment]";
|
|
4
3
|
const description = "Deploy to baremetal server(s)";
|
|
5
4
|
const builder = (yargs) => {
|
|
@@ -79,22 +78,8 @@ const builder = (yargs) => {
|
|
|
79
78
|
);
|
|
80
79
|
};
|
|
81
80
|
async function handler(yargs) {
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
firstRun: yargs.firstRun,
|
|
85
|
-
df: yargs.df,
|
|
86
|
-
update: yargs.update,
|
|
87
|
-
install: yargs.install,
|
|
88
|
-
migrate: yargs.migrate,
|
|
89
|
-
build: yargs.build,
|
|
90
|
-
restart: yargs.restart,
|
|
91
|
-
cleanup: yargs.cleanup,
|
|
92
|
-
maintenance: yargs.maintenance,
|
|
93
|
-
rollback: yargs.rollback,
|
|
94
|
-
verbose: yargs.verbose
|
|
95
|
-
});
|
|
96
|
-
const { handler: baremetalHandler } = await import("./baremetal/baremetalHandler.js");
|
|
97
|
-
return baremetalHandler(yargs);
|
|
81
|
+
const { handler: importedHandler } = await import("./baremetal/baremetalHandler.js");
|
|
82
|
+
return importedHandler(yargs);
|
|
98
83
|
}
|
|
99
84
|
export {
|
|
100
85
|
builder,
|
|
@@ -32,7 +32,7 @@ const handler = async ({
|
|
|
32
32
|
async function runApiCommands() {
|
|
33
33
|
if (!serve) {
|
|
34
34
|
console.log("Building api...");
|
|
35
|
-
await runExecaCommand("yarn
|
|
35
|
+
await runExecaCommand("yarn rw build api --verbose");
|
|
36
36
|
if (prisma) {
|
|
37
37
|
console.log("Running database migrations...");
|
|
38
38
|
await runExecaCommand(
|
|
@@ -41,7 +41,7 @@ const handler = async ({
|
|
|
41
41
|
}
|
|
42
42
|
if (dataMigrate) {
|
|
43
43
|
console.log("Running data migrations...");
|
|
44
|
-
await runExecaCommand("yarn
|
|
44
|
+
await runExecaCommand("yarn rw dataMigrate up");
|
|
45
45
|
}
|
|
46
46
|
return;
|
|
47
47
|
}
|
|
@@ -56,7 +56,7 @@ const handler = async ({
|
|
|
56
56
|
}
|
|
57
57
|
async function runWebCommands() {
|
|
58
58
|
console.log("Building web...");
|
|
59
|
-
await runExecaCommand("yarn
|
|
59
|
+
await runExecaCommand("yarn rw build web --verbose");
|
|
60
60
|
}
|
|
61
61
|
if (side === "api") {
|
|
62
62
|
await runApiCommands();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cedarjs/cli",
|
|
3
|
-
"version": "3.0.0-
|
|
3
|
+
"version": "3.0.0-rc.112",
|
|
4
4
|
"description": "The CedarJS Command Line",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -33,16 +33,16 @@
|
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@babel/parser": "7.29.2",
|
|
35
35
|
"@babel/preset-typescript": "7.28.5",
|
|
36
|
-
"@cedarjs/api-server": "3.0.0-
|
|
37
|
-
"@cedarjs/cli-helpers": "3.0.0-
|
|
38
|
-
"@cedarjs/fastify-web": "3.0.0-
|
|
39
|
-
"@cedarjs/internal": "3.0.0-
|
|
40
|
-
"@cedarjs/prerender": "3.0.0-
|
|
41
|
-
"@cedarjs/project-config": "3.0.0-
|
|
42
|
-
"@cedarjs/structure": "3.0.0-
|
|
43
|
-
"@cedarjs/telemetry": "3.0.0-
|
|
44
|
-
"@cedarjs/utils": "3.0.0-
|
|
45
|
-
"@cedarjs/web-server": "3.0.0-
|
|
36
|
+
"@cedarjs/api-server": "3.0.0-rc.112",
|
|
37
|
+
"@cedarjs/cli-helpers": "3.0.0-rc.112",
|
|
38
|
+
"@cedarjs/fastify-web": "3.0.0-rc.112",
|
|
39
|
+
"@cedarjs/internal": "3.0.0-rc.112",
|
|
40
|
+
"@cedarjs/prerender": "3.0.0-rc.112",
|
|
41
|
+
"@cedarjs/project-config": "3.0.0-rc.112",
|
|
42
|
+
"@cedarjs/structure": "3.0.0-rc.112",
|
|
43
|
+
"@cedarjs/telemetry": "3.0.0-rc.112",
|
|
44
|
+
"@cedarjs/utils": "3.0.0-rc.112",
|
|
45
|
+
"@cedarjs/web-server": "3.0.0-rc.112",
|
|
46
46
|
"@listr2/prompt-adapter-enquirer": "4.2.1",
|
|
47
47
|
"@opentelemetry/api": "1.9.0",
|
|
48
48
|
"@opentelemetry/core": "1.30.1",
|
|
@@ -105,5 +105,5 @@
|
|
|
105
105
|
"publishConfig": {
|
|
106
106
|
"access": "public"
|
|
107
107
|
},
|
|
108
|
-
"gitHead": "
|
|
108
|
+
"gitHead": "d907ae5dbc73ecf4d84f753a521242a9164b6f5a"
|
|
109
109
|
}
|