@elmohq/cli 0.2.6 → 0.2.8

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.
Files changed (2) hide show
  1. package/dist/index.js +12 -14
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -939,6 +939,7 @@ function buildComposeYaml(options) {
939
939
  if (options.postgresMode === "docker") {
940
940
  services.push(buildPostgresService());
941
941
  services.push(buildDbMigrateService({
942
+ dev: options.dev,
942
943
  dockerfilePath,
943
944
  repoRoot: options.repoRoot,
944
945
  }));
@@ -991,18 +992,15 @@ function buildPostgresService() {
991
992
  ].join("\n");
992
993
  }
993
994
  function buildDbMigrateService(options) {
994
- return [
995
- "db-migrate:",
996
- " build:",
997
- ` context: ${options.repoRoot}`,
998
- ` dockerfile: ${options.dockerfilePath}`,
999
- " target: migrate",
1000
- " environment:",
1001
- " - DATABASE_URL=postgres://postgres:postgres@postgres:5432/elmo",
1002
- " depends_on:",
1003
- " postgres:",
1004
- " condition: service_healthy",
1005
- ].join("\n");
995
+ const lines = ["db-migrate:"];
996
+ if (options.dev) {
997
+ lines.push(" build:", ` context: ${options.repoRoot}`, ` dockerfile: ${options.dockerfilePath}`, " target: migrate");
998
+ }
999
+ else {
1000
+ lines.push(" image: elmohq/elmo-db-migrate:latest");
1001
+ }
1002
+ lines.push(" environment:", " - DATABASE_URL=postgres://postgres:postgres@postgres:5432/elmo", " depends_on:", " postgres:", " condition: service_healthy");
1003
+ return lines.join("\n");
1006
1004
  }
1007
1005
  function buildWebService(options) {
1008
1006
  const lines = ["web:"];
@@ -1010,7 +1008,7 @@ function buildWebService(options) {
1010
1008
  lines.push(" build:", ` context: ${options.repoRoot}`, ` dockerfile: ${options.dockerfilePath}`, " target: web", " args:", " DEPLOYMENT_MODE: local");
1011
1009
  }
1012
1010
  else {
1013
- lines.push(" image: elmohq/web:latest");
1011
+ lines.push(" image: elmohq/elmo-web:latest");
1014
1012
  }
1015
1013
  lines.push(" env_file:", " - path: .env", " required: true", " ports:", ' - "1515:3000"');
1016
1014
  if (options.dependsOn.length > 0) {
@@ -1028,7 +1026,7 @@ function buildWorkerService(options) {
1028
1026
  lines.push(" build:", ` context: ${options.repoRoot}`, ` dockerfile: ${options.dockerfilePath}`, " target: worker", " args:", " DEPLOYMENT_MODE: local");
1029
1027
  }
1030
1028
  else {
1031
- lines.push(" image: elmohq/worker:latest");
1029
+ lines.push(" image: elmohq/elmo-worker:latest");
1032
1030
  }
1033
1031
  lines.push(" env_file:", " - path: .env", " required: true");
1034
1032
  if (options.dependsOn.length > 0) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elmohq/cli",
3
- "version": "0.2.6",
3
+ "version": "0.2.8",
4
4
  "license": "AGPL-3.0-or-later",
5
5
  "keywords": [
6
6
  "marketing",
@@ -28,10 +28,10 @@
28
28
  ],
29
29
  "type": "module",
30
30
  "dependencies": {
31
- "@clack/prompts": "^1.2.0",
31
+ "@clack/prompts": "^1.3.0",
32
32
  "commander": "^14.0.3",
33
33
  "picocolors": "^1.1.1",
34
- "posthog-node": "^5.30.4",
34
+ "posthog-node": "^5.33.0",
35
35
  "semver": "^7.7.4"
36
36
  },
37
37
  "devDependencies": {