|
| 1 | +# NextDeploy |
| 2 | + |
| 3 | +Deploy Next.js apps to a VPS, AWS Lambda, or Cloudflare Workers from one |
| 4 | +config file and one command. Open source, self-hosted, no vendor lock-in. |
| 5 | + |
| 6 | +```bash |
| 7 | +curl -fsSL https://nextdeploy.org/install.sh | bash |
| 8 | +``` |
| 9 | + |
| 10 | +Windows: download `install.bat` from <https://nextdeploy.org/install.bat>. |
| 11 | + |
| 12 | +## Quick start |
| 13 | + |
| 14 | +```bash |
| 15 | +nextdeploy init # scaffold nextdeploy.yml in your Next.js repo |
| 16 | +nextdeploy plan # show what will happen, change nothing |
| 17 | +nextdeploy ship # build + push + deploy to your target |
| 18 | +nextdeploy logs -f # tail production logs |
| 19 | +``` |
| 20 | + |
| 21 | +`nextdeploy.yml` holds everything — target type, domain, server, secrets |
| 22 | +provider. See `sample.nextdeploy.yml` in this repo for the full schema. |
| 23 | + |
| 24 | +## Targets |
| 25 | + |
| 26 | +| Target | Status | What it gives you | |
| 27 | +| --------------- | ------ | -------------------------------------------------- | |
| 28 | +| **VPS** | stable | Docker + Caddy + the `nextdeployd` daemon over SSH | |
| 29 | +| **AWS** | stable | Lambda + S3 + CloudFront, full SSR/ISR/image opt | |
| 30 | +| **Cloudflare** | beta | Workers + R2 + KV via the `nextcompile` adapter | |
| 31 | + |
| 32 | +## Build from source |
| 33 | + |
| 34 | +```bash |
| 35 | +git clone https://github.com/aynaash/NextDeploy |
| 36 | +cd NextDeploy |
| 37 | +go build -o nextdeploy ./cli |
| 38 | +``` |
| 39 | + |
| 40 | +Requires Go 1.25+. The release binaries on GitHub are built with |
| 41 | +GoReleaser; see `.goreleaser.yml`. |
| 42 | + |
| 43 | +## Repository layout |
| 44 | + |
| 45 | +``` |
| 46 | +cli/ Cobra CLI entry, all top-level commands |
| 47 | +daemon/ nextdeployd — the agent that runs on each VPS |
| 48 | +shared/nextcompile/ Build-time compiler + JS runtime for CF Workers |
| 49 | +shared/nextcore/ Next.js project introspection (config, routes, deps) |
| 50 | +cli/internal/serverless/ AWS adapter (Lambda, S3, CloudFront, ACM) |
| 51 | +sample.nextdeploy.yml Annotated reference config |
| 52 | +``` |
| 53 | + |
| 54 | +## Documentation |
| 55 | + |
| 56 | +- Full docs: <https://nextdeploy.org/docs> |
| 57 | +- Sample config: [`sample.nextdeploy.yml`](./sample.nextdeploy.yml) |
| 58 | +- Each command also has `nextdeploy <cmd> explain` for inline help |
| 59 | + |
| 60 | +## Contributing |
| 61 | + |
| 62 | +Issues and PRs welcome. Run `go test ./...` before pushing — the release |
| 63 | +pipeline is gated on a green test run. For larger changes, open an issue |
| 64 | +first so we can align on direction. |
| 65 | + |
| 66 | +## License |
| 67 | + |
| 68 | +MIT — see [LICENSE](./LICENSE). |
0 commit comments