Nextjs
Source:
src/Railway/Website/Nextjs.ts
Deploy a Next.js application to Railway as a long-running Node process:
next build, then a serve entry that import("next") +
next({ dev: false }).prepare() + getRequestHandler() on PORT
(default 3000). Not OpenNext — those wrappers are Lambda/workerd.
The image npm installs next, react, and react-dom, and bakes
.next plus public/ into /app.
During alchemy dev the site is Next’s own dev server (next dev) and
no cloud resources are declared; Alchemy.remote() opts back into the
full live deployment.
Creating Next.js Sites
Section titled “Creating Next.js Sites”const site = yield* Railway.Website.Nextjs("Web", { rootDir: "./app",});Server Configuration
Section titled “Server Configuration”const site = yield* Railway.Website.Nextjs("Web", { rootDir: "./app", env: { API_BASE: "https://api.example.com", },});