@webhikers/cli 1.1.13 → 1.1.15

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webhikers/cli",
3
- "version": "1.1.13",
3
+ "version": "1.1.15",
4
4
  "description": "CLI for creating and deploying webhikers projects",
5
5
  "type": "module",
6
6
  "bin": {
@@ -1,5 +1,5 @@
1
1
  import { execSync } from "child_process";
2
- import { existsSync, writeFileSync } from "fs";
2
+ import { existsSync, readFileSync, writeFileSync } from "fs";
3
3
  import { resolve } from "path";
4
4
  import { loadConfig, getConfigPath } from "../utils/config-store.js";
5
5
 
@@ -162,11 +162,14 @@ export async function createCommand(name) {
162
162
  });
163
163
  const appUuid = app.uuid;
164
164
 
165
- console.log(c.dim(` Setting domain...`));
165
+ console.log(c.dim(` Loading compose file and setting domain...`));
166
+ const composeContent = readFileSync(resolve(projectDir, "docker-compose.yaml"), "utf-8");
167
+ const composeBase64 = Buffer.from(composeContent).toString("base64");
166
168
  await coolifyApi(config, "PATCH", `/applications/${appUuid}`, {
167
- docker_compose_domains: JSON.stringify([
169
+ docker_compose_raw: composeBase64,
170
+ docker_compose_domains: [
168
171
  { name: "app", domain: `https://${domain}` },
169
- ]),
172
+ ],
170
173
  });
171
174
 
172
175
  console.log(c.dim(" Setting environment variables..."));