Set Up a $4/Mo Hetzner VM to Skip the Serverless Tax
The article outlines a beginner-friendly guide to setting up a Hetzner virtual machine for $4/month, covering SSL installation, DNS configuration, and web application deployment using GitHub and PM2.
Read original articleThis article provides a step-by-step guide on setting up a virtual machine (VM) on Hetzner for $4 per month, allowing users to avoid the costs associated with serverless architectures. The tutorial is aimed at beginners and covers the installation of Caddy for SSL, configuration of Cloudflare for DNS, and deployment of a web application using GitHub. Key prerequisites include purchasing a domain and generating an SSH key for secure access. The setup process involves registering on Hetzner, configuring Cloudflare, and installing Caddy to manage SSL certificates automatically. Additionally, the guide explains how to integrate a GitHub repository for manual deployment and includes instructions for setting up a simple Node.js application that restarts automatically using PM2. The article emphasizes the simplicity of the process and encourages users to explore further options like Docker for easier management and automatic deployments.
- Setting up a Hetzner VM can save costs compared to serverless architectures.
- The tutorial is beginner-friendly and avoids complex tools like Docker initially.
- Caddy is used for automatic SSL management, enhancing website security.
- Users can manually deploy applications from GitHub after setting up SSH keys.
- PM2 is recommended for managing Node.js applications and ensuring they restart automatically.
Related
Hetzner Cloud Expands to Singapore
Hetzner Cloud has launched services in Singapore, enhancing connectivity to Asia. Users can configure flexible cloud servers starting at €7.90 per month, with options for geo-redundant setups across locations.
Hetzner Cloud – Singapore location available
Hetzner Cloud has opened a new data center in Singapore, redesigned its activities page, introduced new server plans with shared Intel® vCPUs, and added a label search feature for resource management.
Cloudflare has made it too easy to access your homelab on the internet
Cloudflare has improved remote access to homelabs since 2017, simplifying setup with tools like Cloudflare Tunnels and Zero Trust, enhancing security and performance for users in about two hours.
Hetzner Pricing
Hetzner Online GmbH controls its data centers and builds its own servers, optimizing costs and performance. Its automated processes and transparent pricing benefit long-term customers, offering flexibility in service cancellation.
OpenBSD 7.5 via QEMU on Hetzner physical machine (no phys. access / KVM console)
The article details installing OpenBSD 7.5 on a Hetzner server using QEMU, involving RAID1 setup, encrypted partitions, and utilizing Hetzner's rescue system for ISO installation without direct access.
- Concerns about security and best practices in the installation process, particularly regarding the use of npm and PM2.
- Debate over the title's accuracy, with some suggesting it is misleading and not representative of the content.
- Discussion on the advantages of Hetzner's pricing and performance compared to cloud services like DigitalOcean and serverless options.
- Comments on the latency issues for users in the USA when using European servers.
- Suggestions for expanding the tutorial to include more advanced topics, such as automated deployments.
But I do sometimes get the impression that the simple approaches are discarded too easily today. You can rent a lot of hardware pretty cheap from Hetzner and the raw power you get is much higher than what you get with cloud services for the same amount of money. Of course the cloud also provides more stuff, but you really pay a hefty price for some of the things you get there (cough traffic).
The difference gets even larger when you look at the Hetzner root servers, that's a lot of CPU, RAM and storage for little money. And renting actual servers does seem to be overlooked a bit at times, often the comparison is between the cloud and actually buying servers and doing everything yourself.
So many startups are bleeding cash because they’ve been convinced by AWS and others they need auto scaling and self healing from day one. Just build the thing, get it running, make it good later.
I always hear great things about Hetzner. I don't know if those comments are just patriotic Europeans or if Hetzner is really that much better than the alternatives.
Update: Hetzer does have USA servers, but apparently not dedicated bare metal servers in USA (only shared/VM).
Transitioning to micro services also makes serverless more appealing since you're getting a separate web server (resiliency) and scaling for free if you need it.
If so, the code/test/deploy loop is certainly much faster with this method than any serverless I've messed with.
Why not explain the "serverless" part a bit more? Say, automatically deploy on a new GitHub commit or something.
1st to install node, an arbitrary script is downloaded and executed without having a look into it. Could do anything with the system.
Then `sudo npm install -g pm2` is called. That means the stuff is installed as root "somewhere" in the system - bypassing debians package management.
Then a "process manager" is installed to start/stop/manage a service - on a system that already has systemd doing the same job.
Is that really the way things should be done? Waiting for the day when the tutorial starts with modifying grub.cfg to directly boot into node.
Related
Hetzner Cloud Expands to Singapore
Hetzner Cloud has launched services in Singapore, enhancing connectivity to Asia. Users can configure flexible cloud servers starting at €7.90 per month, with options for geo-redundant setups across locations.
Hetzner Cloud – Singapore location available
Hetzner Cloud has opened a new data center in Singapore, redesigned its activities page, introduced new server plans with shared Intel® vCPUs, and added a label search feature for resource management.
Cloudflare has made it too easy to access your homelab on the internet
Cloudflare has improved remote access to homelabs since 2017, simplifying setup with tools like Cloudflare Tunnels and Zero Trust, enhancing security and performance for users in about two hours.
Hetzner Pricing
Hetzner Online GmbH controls its data centers and builds its own servers, optimizing costs and performance. Its automated processes and transparent pricing benefit long-term customers, offering flexibility in service cancellation.
OpenBSD 7.5 via QEMU on Hetzner physical machine (no phys. access / KVM console)
The article details installing OpenBSD 7.5 on a Hetzner server using QEMU, involving RAID1 setup, encrypted partitions, and utilizing Hetzner's rescue system for ISO installation without direct access.