6 ms·
Kubernetes brings more than just being Google. In a way it’s also an ecosystem.
by k8sToGo 2y ago
Kubernetes brings more than just being Google. In a way it’s also an ecosystem.
- steve1977 2y agoThat‘s nice, but the question is if you (i.e. your company) needs this ecosystem.
- k8sToGo 2y agoNeed no. But it’s nice especially since I have the know how. Creating a new deployment is just super fast. Developers can deploy their own apps etc. And then there is Helm. If we only decide by “need” then most of the time we also wouldn’t need object oriented programming.
- sofixa 2y ago> And then there is Helm Right, who doesn't want to template hundreds of lines of code in a language that uses whitespace for logic and was never made neither for templating nor complex long documents(YAML)? What could possibly go wrong ("error missing xxx at line 728, but it might be a problem elsewhere").
- xnickb 2y agoBut my infrastructure is code! Can't you see how it's all in git?
- benterix 2y agoWhat's wrong with having your infrastructure as code and storing it in Git?
- sofixa 2y agoNothing. Even if it's objectively terrible (thousands of lines of templated YAML, or thousands of lines of spaghetti bash), being in Git as code is still better. At least you know what it is, how it evolved, and can start adding linting/tests.
- benterix 2y agoI manage large IaC repos and it's mostly HCL, well-structured and easy to work with. Where we have Kubernetes manifests, they're usually split into smaller files and don't cause any trouble as normally we usually don't deploy manifests directly.
- xnickb 2y agoYAML isn't code. Same as your reply, YAML has very little awareness of context.
- benterix 2y agoIn computer science, the word "code" has a very specific meaning, and markup languages definitely fit this definition.
- spoiler 2y agoHonestly, Helm kinda sucks (for all the reasons you mentioned). But Kustomize is very nice. Although, their docs could be a bit better.
- fredrb 2y agoIt’s not that bad if you need to deploy at least 3 things and for most cases it beats the alternatives. You can get away with a bootstrapped deployment yaml and a couple of services for most scenarios. What should you use instead? Vendor locked app platforms? Roll out your own deploy bash scripts? Sure the full extend of Kubernetes is complicated and managing it might be a pain, but if you don’t go bonkers is not that hard to use it as a developer.
- ithkuil 2y agoI wonder why people don't use fromYaml + toJson to avoid stupid errors with indent. Yaml is for all intents and purposes a superset of JSON so if you render your subtree as JSON you can stick it in a Yaml file and you don't need to care with indentation.
- ndthrowaway 2y ago"in a language that uses whitespace for logic" This argument kind of died when python became one of the most popular programming languages used.
- everforward 2y agoIt’s not completely that white space is bad, but in particular that white space is very difficult to template relative to something character-delimited like JSON or s expressions. In JSON or s expressions, the various levels of objects can be built independently because they don’t rely on each other. In YAML, each block depends on its parent to know how far it should be indented, which is a huge pain in the ass when templating.
- oblio 2y agoYeah, but Python has actual for loops.
- cassianoleal 2y agoPython uses whitespace for scoping - not for logic. That said, the same is true for YAML.
- k8sToGo 2y agoI don’t like helm itself. But I was referring to the deployment part. I like Kustomize more.
- sgarland 2y agoI’ve only ever seen a single dev team managing their own K8s cluster. If by deploy you mean “they merge a branch which triggers a lot of automation that causes their code to deploy,” you don’t need K8s for that. Don’t get me wrong, I like K8s and run it at home, and I’d take it any day over ECS or the like at work, but it’s not like you can’t achieve a very similar outcome without it.
- k8sToGo 2y agoOf course. And I can achieve a Webserver in C. Doesn’t mean it’s the best way given the circumstances. There are many ways in tech to achieve the same result. I don’t understand why people constantly need to point that out. I also don’t understand why k8s ruffles so many feathers. Reminds me a bit of Linux vs windows vs Mac debates.
- sgarland 2y agoK8s ruffles my feathers because it’s entirely too easy to build on it (without proper IaC, natch) without having any clue how it works, let alone the underlying OS that’s mostly abstracted away. /r/kubernetes is more or less “how do I do <basic thing I could have read docs for>.” I’m a fan of graduated difficulty. Having complex, powerful systems should require that you understand them, else when they break – and they will, because they’re computers – you’ll be utterly lost.
- koliber 2y agoLot's of things are nice to have but are expensive. I'd love to have a private pool in my backyard. I don't, even though it's nice to have, because it is too expensive. We intuitively make cost-benefit choices in our private lives. When it comes to deciding the same things at work, our reasoning often goes haywire. Sometimes we need an expensive thing to solve a real problem. Your point about object-oriented programming makes sense. Sometimes, a bash script suffices, and the person who decides to implement that same functionality in Java is just wasting resources. All of these solutions have a place where they make sense. When they are blindly applied because they're a fad they generate a lot of costs.
- k8sToGo 2y agoThat’s true. Using k8s to host a static website would be silly. Generally I only use it when I see a compelling case for it and the introduced complexity takes away complexity from somewhere else.
- Kirth 2y agoGenuine question: say you have 3-4 services and a bunch of databases that make up your product, what's the alternative to plemping them all into K8s according to you?
- benterix 2y agoIf you use AWS, it's probably easier to use ECS that takes away some of the complexity from you.
- sgarland 2y agoMaybe at first, but once you start building all of the IaC and tooling to make it useful and safe at scale, you might as well have just run EKS. Plus, then you can get Argo, which is IMO the single best piece of software from an SRE perspective.
- kaba0 2y agoFor personal stuff I simply run systemd services and that does scale quite a lot (as in, you can rely on it for more production services) I believe.
- sgarland 2y agoMy hero.
- deleted 2y ago[deleted]
- Myoklov 2y agoUsing cloud platform as a service options. For example, on Azure you can deploy such system with Azure App Service (with container deployment), or Azure Container Apps (very suitable for microservices). For database, you can use Azure Database for PostgreSQL (flexible), or Azure Cosmos DB for PostgreSQL. This way, Azure does most of the heavy lifting you would otherwise have to do yourself, even with managed kubernetes.