Live data from Hacker News

Why is Kubernetes getting so popular?

stackoverflow.blog

151–160 of 681 posts

Re: Why is Kubernetes getting so popular?

#151

The simple answer is that Kubernetes isn't really any of the things it's been described as. What it /is/, though, is an operating system for the Cloud. It's a set of universal abstraction layers that can sit on top of and work with any IaaS provider and allows you to build and deploy applications using infrastructure-as-code concepts through a standardized and approachable API. Most companies who were late on the Clo…

IaaS is not "the cloud". it was in 2008 when all we had was EC2 and RDS. Today Kubernetes is the antithesis of the cloud - Instead of consuming resources on demand you're launching VMs that need to run 24/7 and have specific roles and names like "master-1". Might as well rent bare-metal servers. It will cost you less.

Doesn't kubernetes also have autoscaling capabilities?

https://kubernetes.io/blog/2016/07/autoscaling-in-kubernetes...

Re: Why is Kubernetes getting so popular?

#152
post #136

Earlier quoted context omitted.

Why do a comparison? K8S runs on AWS and GCP. They have managed services for setting up one. If you know K8S as a developer, then you simply consume the cloud K8S cluster.

I think the point is that there are people that claim that k8s adds a ton of complexity to your environment. But if you compare k8s alone with managing your infrastructure using (non-k8s) AWS or GCP primitives, you'll find that the complexity is similar.

While that's true on the managing instances side, you also need to actually deploy the infrastructure to manage them (If you're not using some PaaS offering). You don't need to do this for other IaaS.

Honestly the last time I looked at k8s was like 5 years ago, but back then it looked like a pretty big pita to admin.

Re: Why is Kubernetes getting so popular?

#154

The simple answer is that Kubernetes isn't really any of the things it's been described as. What it /is/, though, is an operating system for the Cloud. It's a set of universal abstraction layers that can sit on top of and work with any IaaS provider and allows you to build and deploy applications using infrastructure-as-code concepts through a standardized and approachable API. Most companies who were late on the Clo…

OS for the cloud is exactly what it is. I see AWS, Azure and GCP as OEMs for cloud, just like Samsung, Oppo, Motorla, etc are OEMs for smartphones. Android was the open source abstraction across these devices. K8s is the open source abstraction across clouds.

The meaning of "app" on top of these two operating system abstractions is entirely different and the comparison probably doesn't extend beyond this. From a computing stack standpoint though, it makes sense.

Re: Why is Kubernetes getting so popular?

#155
post #24

I host about a dozen rails apps of different vintage and started switching from Dokku to Digital Ocean Kubernetes. I had a basic app deployed with load balancer and hosted DB in about 6 hours. Services like the nginx ingress are very powerful and it all feels really solid. I never understood Dokku internals either so them being vastly simpler is no help for me. I figured for better or worse kubernetes is here to stay…

I found deploying databases with Dokku to be really intuitive. CockroachDB is great, but still a lot more steps than dokku postgres:create . The whole certificates thing is quite confusing. Otherwise, k3s on-prem is great

Re: Why is Kubernetes getting so popular?

#156

The simple answer is that Kubernetes isn't really any of the things it's been described as. What it /is/, though, is an operating system for the Cloud. It's a set of universal abstraction layers that can sit on top of and work with any IaaS provider and allows you to build and deploy applications using infrastructure-as-code concepts through a standardized and approachable API. Most companies who were late on the Clo…

IaaS is not "the cloud". it was in 2008 when all we had was EC2 and RDS. Today Kubernetes is the antithesis of the cloud - Instead of consuming resources on demand you're launching VMs that need to run 24/7 and have specific roles and names like "master-1". Might as well rent bare-metal servers. It will cost you less.

> Might as well rent bare-metal servers

In light of this statement, what do you make of the fact that billions of dollars are spent on EC2? And of the people who spend that money?

Re: Why is Kubernetes getting so popular?

#157

The simple answer is that Kubernetes isn't really any of the things it's been described as. What it /is/, though, is an operating system for the Cloud. It's a set of universal abstraction layers that can sit on top of and work with any IaaS provider and allows you to build and deploy applications using infrastructure-as-code concepts through a standardized and approachable API. Most companies who were late on the Clo…

IaaS is not "the cloud". it was in 2008 when all we had was EC2 and RDS. Today Kubernetes is the antithesis of the cloud - Instead of consuming resources on demand you're launching VMs that need to run 24/7 and have specific roles and names like "master-1". Might as well rent bare-metal servers. It will cost you less.

Does cloud really mean "resources on demand"?

Re: Why is Kubernetes getting so popular?

#158

Earlier quoted context omitted.

I'm not intimately familiar with those, but I did a lot of similar things with scripts. As far as I can tell: those are imperative. At least in some areas. Kubernetes is declarative. You mention the end state and it just "figures it out". Mind you, with issues sometimes. All abstractions leak. Note that k8s's adamance about declarative configuration can make you bend over backwards. Example: running a migration scrip…

I've only ever used cfengine and Ansible, but they are both declarative. Hell, Ansible uses yaml files too. I would be somewhat surprised to find out Puppet and Chef weren't declarative either. Because setting up a system in an imperative fashion is ripe for trouble. You may as well use bash scripts at that point. I've used Ansible for close to 10 years for hobby projects. And setting up my development environment. G…

Chef can be declarative. If you stick to the resources and templatized config files.

But it has full power of ruby at your disposal (both at load/compile time and run time). So it usually turns imperative quickly.

Re: Why is Kubernetes getting so popular?

#159

Earlier quoted context omitted.

Check out nix for actual development environments. Huge fan of that as well. I can buy a new laptop and be back to 100% in a few minutes. Though the amount of time I spent learning how to get there far exceeds any time savings. Ever.

I've been testing out nix and I haven't found out how to install packages in a declarative way yet. Using "nix-env -iA ` seems really imperative. How are you doing that? Do you use something like home-manager, or do you just define a default.nix and then nix-shell it whenever you need something?

Yes `nix-env -iA` is installing packages in an imperative way. I think it is there to be some kind of tool that people from other OS can relate to. Purist say you should avoid using it for installing packages and instead list global packages in `/etc/nixos/configuration.nix` for globally installed packages and home-manager for user specific ones, and if you need temporarily just to try something out use `nix-shell -p `.

Back to your second question, you can configure the system through `/etc/nixos/configuration.nix` it is enough to configure system as a service. Pretty much everything you could do through Chef/Puppet/Saltstack/Ansible/CFEngine etc.

home-manager is taking it a step further and do this kind of configuration per user. It is actually written in a way that can be added to NixOS (or nix-darwin for OS X users) to integrate with the main configuration so then when you're declaring users you can also provide a configuration for each of them.

So it all depends what you want to do, the main configuration.nix is good enough if your machine to run specific service, that's pretty much all you need, you don't care about each user configuration in that scenario, you just create users and start services using them.

If you have a workstation, home-manager while not essential can be used to take care of setting up your individual user settings, stuff like dot-files (although it goes beyond that). The benefit of using home-manager is that most of what you configure in it should be reusable on OS X as well.

If you care about local development, you can use Nix to declare what is needed, for example[1]. This is especially awesome if you have direnv + lorri installed

you can add these to home-manager configuration:

    programs.direnv.enable = true;
    services.lorri.enable = true;
When you do that you magically will get your CDE (that includes all needed tools, in this case proper python version, you also enter equivalent of virtualenv with all dependencies installed and extra tools) by just entering the directory, if you don't have them installed all you have to do is just call `nix-shell`.

I also can't wait when Flakes[2] get merged. This will standardize setup like this and enable other possibilities.

[1] https://github.com/takeda/example_python_project

[2] https://www.tweag.io/blog/2020-05-25-flakes/

Re: Why is Kubernetes getting so popular?

#160
post #92

Earlier quoted context omitted.

You say that like it's a bad thing. A declarative model is infinitely better for representing complex systems than scripts and mind space. The challenge is actually being able to get to that point.

Until it breaks.

No, even then it's still better. A broken declarative model is better than a broken script.
Post reply on HN