An example deploying Next / Postgres / Nginx to a Ubuntu Linux server.
by leerobTypeScript
Last 12 weeks · 2 commits
1 of 6 standards met
Update all dependencies to their latest versions, including Next.js 16, and apply required migration changes for compatibility. [!NOTE] Medium Risk Medium risk due to the major Next.js upgrade and TypeScript compiler setting changes, which can introduce build/runtime regressions and type-check differences. The export rename may break request protection if it was relied on by Next’s middleware loader. Overview Upgrades core dependencies to newer major/minor versions (including Next.js 16, , , , React, and TypeScript), and pins React type packages via . Updates for the newer toolchain (switches to and expands to cover ). Renames the exported function in from to while keeping the same cookie-based redirect behavior for , which may affect how Next detects and runs middleware. Written by Cursor Bugbot for commit 4ce2f87031035e461af8d204a9719c05f2c11df6. This will update automatically on new commits. Configure here. Cursor Bugbot reviewed your changes and found no issues for commit 4ce2f87
Repository: leerob/next-self-host. Description: An example deploying Next / Postgres / Nginx to a Ubuntu Linux server. Stars: 1495, Forks: 208. Primary language: TypeScript. Languages: TypeScript (59.3%), Shell (24.1%), JavaScript (14.6%), Dockerfile (2%). Open PRs: 0, open issues: 3. Last activity: 1mo ago. Community health: 28%. Top contributors: leerob, aldrickdev, b3v21, tuladhar, dev-kraken.
Greetings folks, I'm trying to self host my project based on the Leerob's guide. The problem is that Leerob hosts a simple next.js application that doesn't generate dynamic metadata that queries the database. My next app tries to connect to the db on the build stage however, the postgres image doesn't boot up before the web image builds. I tried healthcheck and condition however, it still boots the web first and the build ends up with a connection error: !Image Here's my Dockerfile Can anyone help me? This might also help others who try to connect to the db on the build stage.
Hey lee, I've been using this repo as a starting point for a project I'm working on and noticed that it's still using a vulnerable version of nextjs (15.1.2) by default. You could argue people should check stuff like this themselves but it's probably good to keep it safe for the noobies (such as myself) out there. I really appreciate this resource, it's been a great starting point for me. Cheers! [!NOTE] Dependency update:** Bumps from to to address security vulnerabilities and keep the framework current. No application code changes; only is updated. Written by Cursor Bugbot for commit 3f487628615d2c7acb705acd06f429f5efe33b31. This will update automatically on new commits. Configure here.
thanks for the tutorial lee! on previous commit, this script shows how to deploy using root user, but for some cases we want to disable root login and give another user sudo privileges to do deployment, i logged in with custom user and with previous command it will throw error like 'permission denied', this update works on my deployment. also when updating, update.sh take the docker image down first then building the new one, which there will be no running website during building new image, updated update.sh will have zero down time deploymen (kinda) and if new container is fail, it will exit without taking the old image down *sorrybadenglish:v