@clubedge/create-clubedge-app 0.23.0 → 0.24.0
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/CHANGELOG.md +7 -0
- package/README.md +11 -10
- package/package.json +3 -3
- package/template/.github/workflows/deploy.yml +3 -2
- package/template/.railway/railway.ts +35 -0
- package/template/README.md +1 -1
- package/template/SETUP.md +3 -1
- package/template/apps/start/package.json +1 -1
- package/template/apps/web/package.json +1 -1
- package/template/clubedge.template.json +1 -1
- package/template/package.json +1 -1
- package/template/packages/auth/package.json +1 -1
- package/template/packages/auth-better-auth/package.json +1 -1
- package/template/packages/auth-supabase/package.json +1 -1
- package/template/packages/cache/package.json +1 -1
- package/template/packages/cache-redis/package.json +1 -1
- package/template/packages/core/package.json +1 -1
- package/template/packages/db/package.json +1 -1
- package/template/packages/email/package.json +1 -1
- package/template/packages/email-resend/package.json +1 -1
- package/template/packages/email-smtp/package.json +1 -1
- package/template/packages/jobs/package.json +1 -1
- package/template/packages/jobs-pg-boss/package.json +1 -1
- package/template/packages/local-db/package.json +1 -1
- package/template/packages/observability/package.json +1 -1
- package/template/packages/observability-otel/package.json +1 -1
- package/template/packages/observability-sentry/package.json +1 -1
- package/template/packages/payments/package.json +1 -1
- package/template/packages/payments-stripe/package.json +1 -1
- package/template/packages/storage/package.json +1 -1
- package/template/packages/storage-s3/package.json +1 -1
- package/template/packages/storage-supabase/package.json +1 -1
- package/template/packages/ui/package.json +1 -1
- package/template.lock.json +3 -3
- package/template/railway.json +0 -13
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to `create-clubedge-app` are documented here.
|
|
4
4
|
|
|
5
|
+
## 0.24.0
|
|
6
|
+
|
|
7
|
+
- Default to Starter `v0.17.0` (#61), which adds:
|
|
8
|
+
- Railway configuration as code: projects that deploy to Railway get `.railway/railway.ts` (the migrations before each release, the `/api/health` check) instead of `railway.json`, which Railway stops reading on 2026-12-01. It names the service after the package, and `pnpm clubedge deploy` applies it before each release.
|
|
9
|
+
- The deploy workflow on Railway CLI 5.
|
|
10
|
+
- If you deploy to Railway: run `pnpm clubedge upgrade`, then deploy once with `pnpm clubedge deploy` (or run `railway config apply`) before 2026-12-01.
|
|
11
|
+
|
|
5
12
|
## 0.23.0
|
|
6
13
|
|
|
7
14
|
- `deploy` moves Railway projects to `.railway/railway.ts`, Railway's configuration as code, which replaces `railway.json`: Railway stops reading `railway.json` on 2026-12-01 (#59).
|
package/README.md
CHANGED
|
@@ -127,7 +127,7 @@ pnpm dlx @clubedge/create-clubedge-app my-app --yes --no-git --framework tanstac
|
|
|
127
127
|
pnpm dlx @clubedge/create-clubedge-app my-app --ref main
|
|
128
128
|
|
|
129
129
|
# Reproduce a specific Starter release or commit
|
|
130
|
-
pnpm dlx @clubedge/create-clubedge-app my-app --ref v0.
|
|
130
|
+
pnpm dlx @clubedge/create-clubedge-app my-app --ref v0.17.0
|
|
131
131
|
pnpm dlx @clubedge/create-clubedge-app my-app --ref <commit-sha>
|
|
132
132
|
|
|
133
133
|
# Test local Starter changes before releasing them
|
|
@@ -146,7 +146,7 @@ pnpm clubedge add email resend payments stripe # several modules as
|
|
|
146
146
|
pnpm clubedge remove storage payments
|
|
147
147
|
pnpm dlx @clubedge/create-clubedge-app add infra local --dry-run
|
|
148
148
|
pnpm dlx @clubedge/create-clubedge-app@latest upgrade # to the newest CLI's Starter release
|
|
149
|
-
pnpm dlx @clubedge/create-clubedge-app upgrade --ref v0.
|
|
149
|
+
pnpm dlx @clubedge/create-clubedge-app upgrade --ref v0.17.0 # or a specific tag, branch, or commit
|
|
150
150
|
```
|
|
151
151
|
|
|
152
152
|
The CLI renders the project twice, from the Starter commit and modules recorded in your `package.json` and from the new state, and merges the difference into your project. The new state has other modules for `add` and `remove`, and the newer Starter with the same modules for `upgrade`. Modules a newer Starter introduces start as `none` where possible, so an upgrade never adds a service on its own.
|
|
@@ -206,27 +206,27 @@ With [Railway's CLI](https://docs.railway.com/cli) (the installed `railway`, or
|
|
|
206
206
|
Each CLI release is tested against one specific Starter release:
|
|
207
207
|
|
|
208
208
|
```text
|
|
209
|
-
create-clubedge-app v0.
|
|
209
|
+
create-clubedge-app v0.24.0
|
|
210
210
|
|
|
|
211
211
|
v
|
|
212
|
-
Clubedge Starter v0.
|
|
213
|
-
commit
|
|
212
|
+
Clubedge Starter v0.17.0
|
|
213
|
+
commit 91be4541de5833527b52a8871a08578f63b89735
|
|
214
214
|
```
|
|
215
215
|
|
|
216
216
|
The current relationship is:
|
|
217
217
|
|
|
218
218
|
| CLI release | Default Starter release | Meaning |
|
|
219
219
|
| --- | --- | --- |
|
|
220
|
-
| `create-clubedge-app@0.
|
|
220
|
+
| `create-clubedge-app@0.24.0` | `clubedge-starter@v0.17.0` | The CLI's required, tested default |
|
|
221
221
|
|
|
222
222
|
This means the same CLI version always scaffolds the same Starter revision by default. The CLI does not silently follow Starter `main`.
|
|
223
223
|
|
|
224
|
-
The `v0.
|
|
225
|
-
`
|
|
224
|
+
The `v0.17.0` tag is expected to resolve to commit
|
|
225
|
+
`91be4541de5833527b52a8871a08578f63b89735`. The CLI verifies this before
|
|
226
226
|
scaffolding with the default reference and fails rather than silently using a
|
|
227
227
|
moved tag.
|
|
228
228
|
|
|
229
|
-
When the Starter changes, its maintainers first publish a new versioned release, such as `v0.
|
|
229
|
+
When the Starter changes, its maintainers first publish a new versioned release, such as `v0.17.0`. The CLI is then updated to use that release, all generated-project checks must pass, and a new CLI version is published. This keeps Starter and CLI releases independently versioned while preserving a tested compatibility relationship.
|
|
230
230
|
|
|
231
231
|
Every generated project records its CLI version, Starter repository, Starter ref, Starter commit, framework, and modules in `package.json` and `README.md`.
|
|
232
232
|
|
|
@@ -281,7 +281,7 @@ CI packs the CLI with `npm pack`, scaffolds clean projects from the packed tarba
|
|
|
281
281
|
1. Make and validate changes in `clubedge-starter`.
|
|
282
282
|
2. Run lint, typecheck, unit tests, browser tests, and production build.
|
|
283
283
|
3. Update the Starter package versions.
|
|
284
|
-
4. Commit `main`, create a release tag such as `v0.
|
|
284
|
+
4. Commit `main`, create a release tag such as `v0.17.0`, and publish the Starter release.
|
|
285
285
|
|
|
286
286
|
### CLI maintainers
|
|
287
287
|
|
|
@@ -314,6 +314,7 @@ Each phase ends with a Starter release and a CLI release pinned to it. The full
|
|
|
314
314
|
| 0.21.0 | v0.16.0 | Starter v0.16.0: upgrades delivered as pull requests, Node 24 actions; release tooling for maintainers |
|
|
315
315
|
| 0.22.0 | v0.16.1 | `pnpm clubedge deploy`: a guided first deploy to Railway; faster Docker builds |
|
|
316
316
|
| 0.23.0 | v0.16.1 | `deploy` moves Railway projects to `.railway/railway.ts` before Railway stops reading `railway.json` |
|
|
317
|
+
| 0.24.0 | v0.17.0 | Starter v0.17.0: Railway configuration as code (`.railway/railway.ts`) instead of `railway.json` |
|
|
317
318
|
| next | | Show the Starter's version of a conflicted file next to yours |
|
|
318
319
|
|
|
319
320
|
## Community
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@clubedge/create-clubedge-app",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.24.0",
|
|
4
4
|
"description": "Create a Next.js or TanStack Start application from the Clubedge Starter reference implementation.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"packageManager": "pnpm@10.9.0",
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
},
|
|
23
23
|
"clubedge": {
|
|
24
24
|
"starterRepository": "Clubedge/clubedge-starter",
|
|
25
|
-
"starterRef": "v0.
|
|
26
|
-
"starterCommit": "
|
|
25
|
+
"starterRef": "v0.17.0",
|
|
26
|
+
"starterCommit": "91be4541de5833527b52a8871a08578f63b89735"
|
|
27
27
|
},
|
|
28
28
|
"license": "Apache-2.0",
|
|
29
29
|
"repository": {
|
|
@@ -54,8 +54,9 @@ jobs:
|
|
|
54
54
|
runs-on: ubuntu-24.04
|
|
55
55
|
steps:
|
|
56
56
|
- uses: actions/checkout@v7
|
|
57
|
-
# Uploads this checkout; Railway builds the image and runs the pre-deploy migrations
|
|
58
|
-
|
|
57
|
+
# Uploads this checkout; Railway builds the image and runs the pre-deploy migrations set by
|
|
58
|
+
# .railway/railway.ts (applied with `pnpm clubedge deploy` or `railway config apply`).
|
|
59
|
+
- run: npx --yes @railway/cli@5 up --ci --service "$RAILWAY_SERVICE"
|
|
59
60
|
env:
|
|
60
61
|
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}
|
|
61
62
|
RAILWAY_SERVICE: ${{ vars.RAILWAY_SERVICE }}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
// Railway's configuration for this project, as code: the migrations before each release and the
|
|
2
|
+
// health check. `pnpm clubedge deploy` applies it before each release; elsewhere, run
|
|
3
|
+
// `railway config apply` once. Railway builds the root Dockerfile; set variables with
|
|
4
|
+
// `railway variable set` or the dashboard.
|
|
5
|
+
import { readFileSync } from "node:fs";
|
|
6
|
+
import { defineRailway, project, service } from "railway/iac";
|
|
7
|
+
|
|
8
|
+
// The Railway service is named after the package, as `pnpm clubedge deploy` creates it. A service
|
|
9
|
+
// you created yourself under another name: put that name here.
|
|
10
|
+
const packageName: string = JSON.parse(
|
|
11
|
+
readFileSync(new URL("../package.json", import.meta.url), "utf8"),
|
|
12
|
+
).name;
|
|
13
|
+
const name =
|
|
14
|
+
packageName
|
|
15
|
+
.replace(/^@[^/]+\//, "")
|
|
16
|
+
.toLowerCase()
|
|
17
|
+
.replace(/[^a-z0-9-]+/g, "-")
|
|
18
|
+
.replace(/^-+|-+$/g, "") || "web";
|
|
19
|
+
|
|
20
|
+
// This repository manages only its own resources in the Railway project.
|
|
21
|
+
export const partial = name;
|
|
22
|
+
|
|
23
|
+
export default defineRailway(() => {
|
|
24
|
+
const app = service(name, {
|
|
25
|
+
// Migrations run before each release; a failed migration stops it.
|
|
26
|
+
preDeploy: "node /app/migrate.mjs",
|
|
27
|
+
healthcheck: "/api/health",
|
|
28
|
+
healthcheckTimeout: 60,
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
return project(name, {
|
|
32
|
+
variables: { managed: false },
|
|
33
|
+
resources: [app],
|
|
34
|
+
});
|
|
35
|
+
});
|
package/template/README.md
CHANGED
|
@@ -74,7 +74,7 @@ Every combination in the CI matrix is generated as a real project and runs its f
|
|
|
74
74
|
- A production image that includes its own migrator (`node /app/migrate.mjs`), for running migrations before each release.
|
|
75
75
|
- A manual deploy workflow for the chosen platform, and a readiness endpoint (`/api/ready`) that checks the database.
|
|
76
76
|
- Deployment to Fly.io with `fly.toml`: migrations run as the release command. <!-- clubedge:only deploy=fly -->
|
|
77
|
-
- Deployment to Railway with
|
|
77
|
+
- Deployment to Railway with `.railway/railway.ts`: migrations run before each release, and `pnpm clubedge deploy` sets up the project. <!-- clubedge:only deploy=railway -->
|
|
78
78
|
- Deployment to Render with a `render.yaml` Blueprint: migrations run before each deploy. <!-- clubedge:only deploy=render -->
|
|
79
79
|
- Deployment to Vercel with `apps/web/vercel.json`: migrations run during the build. <!-- clubedge:only deploy=vercel -->
|
|
80
80
|
- Deployment to Netlify with `apps/web/netlify.toml`: migrations run during the build. <!-- clubedge:only deploy=netlify -->
|
package/template/SETUP.md
CHANGED
|
@@ -390,7 +390,9 @@ Set the other production variables listed below with `fly secrets set`. Each dep
|
|
|
390
390
|
<!-- clubedge:end -->
|
|
391
391
|
<!-- clubedge:if deploy=railway -->
|
|
392
392
|
|
|
393
|
-
|
|
393
|
+
`.railway/railway.ts` is the service's configuration on [Railway](https://railway.com), as code: Railway builds the root `Dockerfile`, runs `node /app/migrate.mjs` before each release, so a failed migration stops it, and checks `/api/health` before switching traffic.
|
|
394
|
+
|
|
395
|
+
The quickest first deploy is `pnpm clubedge deploy`: it creates the project, Postgres, the service, its domain and variables, applies `.railway/railway.ts`, and deploys. To deploy another way, add Railway's TypeScript SDK with `pnpm add -D -w railway`, run `railway config apply` once (Railway CLI 5.42.1 or newer), and add the production variables listed below to the service. The file names the service after the package; if yours has another name, change it there.
|
|
394
396
|
|
|
395
397
|
<!-- clubedge:end -->
|
|
396
398
|
<!-- clubedge:if deploy=render -->
|
package/template/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@clubedge/observability",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.17.0",
|
|
4
4
|
"description": "Observability interface: error reports and spans for @clubedge/core's telemetry hooks, and an in-memory provider for tests.",
|
|
5
5
|
"private": true,
|
|
6
6
|
"license": "Apache-2.0",
|
package/template.lock.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"repository": "Clubedge/clubedge-starter",
|
|
3
|
-
"ref": "v0.
|
|
4
|
-
"commit": "
|
|
3
|
+
"ref": "v0.17.0",
|
|
4
|
+
"commit": "91be4541de5833527b52a8871a08578f63b89735",
|
|
5
5
|
"files": [
|
|
6
6
|
".dockerignore",
|
|
7
7
|
".env.example",
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
"_gitignore",
|
|
17
17
|
".prettierignore",
|
|
18
18
|
".prettierrc.json",
|
|
19
|
+
".railway/railway.ts",
|
|
19
20
|
"AGENTS.md",
|
|
20
21
|
"CODE_OF_CONDUCT.md",
|
|
21
22
|
"CONTRIBUTING.md",
|
|
@@ -378,7 +379,6 @@
|
|
|
378
379
|
"playwright.config.ts",
|
|
379
380
|
"pnpm-lock.yaml",
|
|
380
381
|
"pnpm-workspace.yaml",
|
|
381
|
-
"railway.json",
|
|
382
382
|
"render.yaml",
|
|
383
383
|
"scripts/build-migrator.mjs",
|
|
384
384
|
"scripts/migrate.mjs",
|
package/template/railway.json
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://railway.com/railway.schema.json",
|
|
3
|
-
"build": {
|
|
4
|
-
"builder": "DOCKERFILE",
|
|
5
|
-
"dockerfilePath": "Dockerfile"
|
|
6
|
-
},
|
|
7
|
-
"deploy": {
|
|
8
|
-
"preDeployCommand": ["node /app/migrate.mjs"],
|
|
9
|
-
"healthcheckPath": "/api/health",
|
|
10
|
-
"healthcheckTimeout": 60,
|
|
11
|
-
"restartPolicyType": "ON_FAILURE"
|
|
12
|
-
}
|
|
13
|
-
}
|