The article calls out having to learn how to create a Docker image for Fly.io as though it's a bad thing. I consider it a huge bonus if you like taking advantage of free tiers for services.
The whole point is that if you're going to take advantage of a free tier you should do so in a way that switching is trivial. Docker goes a long way to achieving that.
I personally just pay $10/month to Linode and self host these days using Nomad. Less restrictions and more freedom for the cost of a coffee and a bagel.
As someone who uses Node.js and is in the exact same situation as the author, requiring Docker is the #1 reason I'm not going with Fly.io. There's a standard for launching a Node.js project, and that's running the "start" script `npm start`, so switching is trivial. I switched from a Linux machine to my current MacBook and I didn't have to make a single change in any of my Node.js projects.
Adding docker means adding a whole new layer to ALL of my projects, which I'd prefer to avoid specially when there's no need as Heroku has very clearly shown.
I hear you, it's nice to run on a platform that understands how to execute your entrypoint to start your program. Docker helps ensure more than that though.
How do your dependencies get installed? What happens if you depend on something in your package.json that isn't on the public npm repo? What happens if you need to compile some native code as part of one of your dependencies?
Do you need to depend on anything provided by the OS? Timezone data? Maybe you use sqlite as a storage backend and want to ship your database file as well. How do you include configuration data?
Docker drastically simplifies packaging and deployment, and gives you a ton of flexibility in where and how you run your code.
Agreed, if you have a complex project Docker helps standardize it. But if you have A LOT of simple projects where none of your points apply, then it actually makes it all more complex.
I installed FreeBSD on a OCI arm machine, made two Jail templates (iocage) and deploy everything that way, backup or redeployment to another host is as easy as zfs-send.
Oracle a problem? No, because my Jails can wander to Vultr, Hetzner (yes they sill support FreeBSD) and Amazon andandand, the only change is a DNS one.
Using Docker is relatively simple and requires little to no configuration, arguably less than a standard node project.
Regardless, as someone who uses a variety of languages and is in the exact same situation, my generic Makefile is probably easier to read and understand than any standard that you have probably achieved.
I don't use any build packs in Heroku? Since a while back Heroku just recognizes the Node project and automatically works with it, no need for any extra file.
Or do you mean it's the same in Fly.io? If it auto-detects Node.js (through package.json), or at most allows for a dropdown to say "Node.js project", then that sounds about right for me.
> At this point, flyctl creates an app for you and writes your configuration to a fly.toml file. You'll then be prompted to build and deploy your app. Once complete, your app will be running on fly.
Well it still creates a fly.toml for you, which is still a new config file that I have to maintain across projects.
You update the toml file once (e.g if you have a release step), and then don't touch it again. Its more powerful than Heroku, so with that it gives you the option of adding additional config options.
I mean it even creates the basic file for you, I'm not sure what the issue is?
I use Time4VPS (which is linked on my blog) or Hetzner for VPSes and Docker Swarm for orchestration (at least for personal stuff, though Nomad or something like K3s can be great too), in combination with a more boring web server like Apache or Nginx for ingress (but Caddy and Traefik are viable as well).
Overall, I'm inclined to agree! You can pick a stack that's as boring or interesting as you want and have your container images work in almost any environment where OCI is supported, with minimal tweaking.
Currently each of my individual nodes cost around 5-10 euros a month, or I can even use my homelab servers for whatever I want, since they can either be in the same cluster or a separate cluster. Essentially you just adjust some deployment constraints and feed some YAML/HCL into whatever container orchestrator you have. Provided that your registry access is configured correctly, you'll have your software up and running in minutes.
Did not mean to imply that Dockerizing applications is a bad thing - actually even pointed out that "it's not so hard". Just wanted to point out that writing one takes some effort and therefore Fly.io is not a drop-in replacement for Heroku.
Container based deployment is a great thing to have and definitely a skill worth learning.
Fly.io seems like the easiest way to get a docker container running publically. I had a look at the AWS equivalent (can't remember the name), and it was a cluster fuck of complementary services in the tutorial.
Wish more cloud providers would focus on helping with existing open source tech, rather than trying to suck you in.
I've found nomad far easier to operate and maintain, and conceptually it's easier to wrap your head around as well. It helps that nomad is just responsible for container orchestration, that's it. You can use whatever you want for ingress routing (I really like traefik).
That’s good to hear. I also like Traefik but I used some Traefik ingress controller on K8s. I really just want an orchestration tool for my containers and nothing else since NGINX and Traefik have nice enough abstractions. Thanks y’all.
The whole point is that if you're going to take advantage of a free tier you should do so in a way that switching is trivial. Docker goes a long way to achieving that.
I personally just pay $10/month to Linode and self host these days using Nomad. Less restrictions and more freedom for the cost of a coffee and a bagel.
https://www.larrymyers.com/posts/nomad-and-traefik/