ezhst 1.3.2 → 1.3.3

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/package.json +1 -1
  2. package/skill/SKILL.md +13 -9
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ezhst",
3
- "version": "1.3.2",
3
+ "version": "1.3.3",
4
4
  "description": "Reverhost CLI: agent-first hosting for Node.js apps with storage and databases",
5
5
  "type": "module",
6
6
  "bin": {
package/skill/SKILL.md CHANGED
@@ -36,19 +36,23 @@ npx ezhst link --project <slug> --json
36
36
 
37
37
  ## 3. Deploy
38
38
 
39
- Every app builds from a Dockerfile stored on the app (a Dockerfile in the repo is ignored, so upload it explicitly). Run inside the app folder:
39
+ Every app builds from a Dockerfile stored on the app, not from a file in the repo. Never create, edit or upload a `Dockerfile` file in the user's project. Always write the Dockerfile straight to the app through the CLI. Run inside the app folder:
40
40
 
41
- 1. Inspect the repo and write a `Dockerfile` (start from `npx ezhst build dockerfile template <id>`; ids: node, bun, python, go, ruby, php, rust, zig).
42
- 2. The app must listen on `0.0.0.0` and `$PORT` (3000).
43
- 3. Env vars are runtime env. If the build step needs them, use `RUN --mount=type=secret,id=appenv,target=/run/secrets/appenv sh -c 'set -a; . /run/secrets/appenv; set +a; <build command>'`. Never put secrets in `ARG` or `ENV`.
44
- 4. Keep the image under 1 GB (slim bases, multi-stage builds for compiled languages). Containers get 256 MB of memory and half a CPU.
45
- 5. Do not use `# syntax=` lines or images from the Reverhost registry; they are rejected.
41
+ 1. Inspect the repo and pick a template: `npx ezhst build dockerfile template --json` lists them, `npx ezhst build dockerfile template <id> --json` returns one. Ids include node, express, nestjs, nextjs, nuxt, sveltekit, react-router, astro, bun, elysia, fastapi, flask, django, streamlit, rails, ruby, laravel, php, go, rust, zig, vite, static. A Dockerfile already in the repo is only a reference: read it, adapt it, and send the result through the CLI like any other.
42
+ 2. Adapt the template to the repo, then save it to the app by piping it through stdin with a quoted heredoc (`<<'EOF'`, so the shell does not expand `$PORT` or `$(...)`). If the template fits unchanged, `npx ezhst build dockerfile template <id> --apply --json` saves it directly.
43
+ 3. The app must listen on `0.0.0.0` and `$PORT` (3000).
44
+ 4. Env vars are runtime env. If the build step needs them, use `RUN --mount=type=secret,id=appenv,target=/run/secrets/appenv sh -c 'set -a; . /run/secrets/appenv; set +a; <build command>'`. Never put secrets in `ARG` or `ENV`.
45
+ 5. Keep the image under 1 GB (slim bases, multi-stage builds for compiled languages). Containers get 256 MB of memory and half a CPU. Download toolchains from fast sources (package managers, official images); a slow download is billed build time and builds stop after 20 minutes.
46
+ 6. Do not use `# syntax=` lines or images from the Reverhost registry; they are rejected.
46
47
 
47
48
  ```
48
49
  npx ezhst apps create <name> --project <project-slug> --json
49
50
  npx ezhst link --project <project-slug> --app <app-slug> --json
50
51
  npx ezhst env import .env --json
51
- npx ezhst build dockerfile set -f Dockerfile --json
52
+ npx ezhst build dockerfile set -f - --json <<'EOF'
53
+ FROM node:22-alpine
54
+ ...
55
+ EOF
52
56
  npx ezhst deploy --json
53
57
  ```
54
58
 
@@ -62,7 +66,7 @@ Common fixes:
62
66
  - Missing env var at build time: `ezhst env set KEY=VALUE`, then `ezhst redeploy`.
63
67
  - `npm ci` says the lockfile is out of sync: delete `node_modules` and `package-lock.json`, run `npm install`, deploy again.
64
68
  - Monorepo: `ezhst build set --root-dir apps/web`.
65
- - Build fails: fix the Dockerfile, `ezhst build dockerfile set -f Dockerfile`, then `ezhst redeploy` (rebuilds the last upload, even a failed one).
69
+ - Build fails: read the stored Dockerfile with `ezhst build dockerfile show --json`, fix it, send it back with `ezhst build dockerfile set -f - <<'EOF'`, then `ezhst redeploy` (rebuilds the last upload, even a failed one).
66
70
  - App starts but the URL fails: it is not listening on `0.0.0.0:$PORT`.
67
71
  - Daily build limit reached (10 per day on Free, 50 on Pro): wait or upgrade; do not loop deploys.
68
72
 
@@ -80,7 +84,7 @@ Projects and runtime:
80
84
  Environment and build:
81
85
  - `env list | set KEY=VALUE... | unset KEY... | import <file>`
82
86
  - `build show`, `build set --root-dir <dir>` (build context, `""` for the project root), `build reset`
83
- - `build dockerfile show`, `build dockerfile set -f <file>` (`-` reads stdin), `build dockerfile template [id] [--apply]`
87
+ - `build dockerfile show`, `build dockerfile set -f -` (reads stdin; agents always use this), `build dockerfile template [id] [--apply]`
84
88
 
85
89
  Custom domains:
86
90
  - `domains list | add <hostname> | verify <hostname> | remove <hostname>`