prutya / website-comments

Blog post comments storage for https://prudkohliad.com
0 stars 0 forks source link

articles/deploy-next-js-to-vps-using-sst-2024-08-11 #3

Open utterances-bot opened 2 months ago

utterances-bot commented 2 months ago

How to deploy a Next.js app to a Hetzner VPS using SST and Docker - Anton Prudkohliad

Learn how to self-host your Next.js application on a Hetzner VPS using SST and Docker for robust and fast deployment.

https://www.prudkohliad.com/articles/deploy-next-js-to-vps-using-sst-2024-08-11

joneslloyd commented 4 days ago

Very, very cool article – Thank you! This has come in handy for me.

I wanted to ask:

What about other things like postgres databases, lambdas, etc?

How do you integrate those into this setup?

prutya commented 3 days ago

Hi @joneslloyd Great to hear that! I have not tried adding postgres, but if I did, I would either install it via another docker container or by using a managed instance at Neon or AWS, for example. Regarding lambdas - they are supported by Pulumi.

joneslloyd commented 3 days ago

Thank you!

I already started trying to do the Container-based route for Postgres.

Another thing:

Have you encountered the situation where the Container is running, and the Next.js app is running inside of the Container (confirmed by logs + going into the Container), and yet it's not accessible from the outside?

prutya commented 3 days ago

No, I have not encountered that. I'd start by checking the port mappings are correct for the container and making sure that traffic for that port is not blocked by the firewall. You could also try to use Cloudflare Tunnels to expose the app to the Internet. The SST setup for them is covered here: https://github.com/prutya/next-self-hosted.

joneslloyd commented 3 days ago

Turns out that it was some T3 error related to the global CSS file for me. All good. Thanks again for your help!