Hardening your servers, ensuring proper port exposure, ensuring upgrades and security patches, is thought and time you need to spend. It's hard to keep track of all vulnerabilities in all software. That'd before even talking about zero-downtime deployments and all of that.
Running NGINX and Postgres is not the difficult part that people are avoiding. There's a good reason these services exist.
which is why i switched to kubernetes
There are some things I’ve deployed without much care and yet they’re always as I left them.
I’m not saying there’s nothing to worry about. I’m just not sure it’s all that difficult with some rudimentary (but sane) security practices.
If you put it out there and don't actively secure it it's bound to get compromised - just a matter of when.
Having said that I never said it was "hard" - just something needs to be done. I responded to a comment that took it for granted that you'd automatically be safe on the Internet.
I'm not saying there can't be a problem, but it's so easy and the alternatives (cloud+terraform+ansible+packer et al.) are so complicated in comparison that it beggars belief that people are choosing an "easy" path here.
Yes, for hobby projects and proofs of concept you can easily get away with a VPS from DigitalOcean or Vultr (are they still around?), but for anything with super variable traffic? Planning to post a link to HackerNews or ProductHunt? Cloudflare Workers and Fauna keep your site online, the VPS crashes.
I much prefer the above, then waking up to my droplet dead on a Tuesday night because I forgot to also rotate my stdout logs.