Skip to main content

Show HN: Magic Happens – let ChatGPT manage your Kubernetes cluster https://ift.tt/Z3wpdcv

Show HN: Magic Happens – let ChatGPT manage your Kubernetes cluster I built this kubernetes operator as a proof of concept this weekend.. It only has a single required item in the spec, a freeform description field. The operator will use chatgpt to generate a spec, then immediately apply it to the cluster. It makes some attempt to correct errors if there's a problem with the syntax. It will leave additional comments, questions or instructions in the status field of the object. I built this in a weekend and it's still quite unrefined. It's in no way production ready, please don't use it for anything real, but it works better than you would think, considering how simple it is. If you're going to use it, run it on a local cluster like 'kind'. Some descriptions to try: * install a redis namespace with a redis cluster and a service in it * create an argocd application in the argocd namespace to install velero. * write a python script that lists all ec2 instances in us-east-1, and run it as a k8s job with the aws credentials already saved in the default namespace.. a somewhat longer description that also worked: given the following spec: --- kind: MagicHappens apiVersion: gptmagic.io/v1 metadata: name: foo spec: description: this is a freeform description field that will be sent to chatgpt to generate kubernetes resources dryRun: false --- Can you create more magic happens resources, each of which describes an argocd application that needs to be created to install a helm chart for one of the standard cluster addons that need to be installed on a cluster for it to be production ready. The description should be be freeform text like the following: "Create an argocd application in the argocd namespace to install istio from the helm chart with all the defaults" or "Create an argocd application in the argocd namespace to install prometheus and grafana, with an ingress enabled for grafana". Be very thorough and included as many apps that might be needed for a prod ready cluster using industry standard CNCF projects if possible. (this produces a list of additional resources for the operator, which the operator then goes on to create argocd applications for -- it also left comments with instructions on one of the resources for how configure it to work with your cloud provider something to note is that since you can run arbitrary containers with arbitrary commands, and chatgpt can write arbitrary code, you don't have to limit yourself to k8s stuff.. if you've got saas credentials on the cluster, you can just tell it to run a python script as a job to do whatever you want. Since most people are cowards, there's a dryRun field that defaults to true, so it only attaches the spec to the object. It is scary how well this works. https://ift.tt/9D4vXnR April 18, 2023 at 12:39AM

Comments

Popular posts from this blog

Women Pioneers at Muni: Adeline Svendsen and Muni’s First Newsletter

Women Pioneers at Muni: Adeline Svendsen and Muni’s First Newsletter By Jeremy Menzies To close out Women’s History Month, here’s a look back at one woman whose work to bring Muni staff together in the late 1940s created a legacy that lives on to this day. Adeline “Addy” Svendsen was founding editor of Muni’s first internal newsletter, “ Trolley Topics .” Adeline Svendsen sits at her desk in the Geneva Carhouse office building in this 1949 shot. Trolley Topics was a new venture when it started in February 1946. As Svendsen wrote in the first issue it was created, “to bring a little fun, a little news, and a lot of good will to all our fellow employees in the Railway.” Just two years prior in 1944, Muni merged with the Market Street Railway Company, expanding the small municipal operation into the largest transit provider in the city with hundreds of employees, vehicles of every shape and size, and dozens of facilities scattered across town. The newsletter was meant to help unite ...

Show HN: StreetComplete, an OpenStreetMap Editor for Humans https://ift.tt/2J8IL02

Show HN: StreetComplete, an OpenStreetMap Editor for Humans StreetComplete is an OpenStreetMap[0] editor directed at people who want to contribute and want to do this using their smartphone, without learning how to edit things[1]. It is available as an Android application. It is intended to be used as one walks, with quests appearing as markers on the map. Selecting a marker allows one to answer a simple question. The answer will be added to the OpenStreetMap database, with app handling selecting objects for editing, transforming answer into OSM tags and making edits. OpenStreetMap account is needed to apply edits, but it is possible to start without it, make some edits and login/register later. Note: I am not the main author, but I am one of the active contributors. Github page is at https://ift.tt/2g8lasH and https://ift.tt/3nR9PzS shows what was recently released. [0]OpenStreetMap is a Wikipedia of maps, available on the open licence. This dataset is already used for many interestin...

Show HN: Launch VM workloads securely and instantaneously, without VMs https://ift.tt/2QwJ1Kd

Show HN: Launch VM workloads securely and instantaneously, without VMs Hello HN! We've been working on a new hypervisor https://kwarantine.xyz that can run strongly isolated containers. This is still a WIP, but we wanted to give the community an idea about our approach, its benefits, and various use cases it unlocks. Today, VMs are used to host containers, and make up for the lack of strong security as well as kernel isolation in containers. This work adds this missing security piece in containers. We plan on launching a free private beta soon. Meanwhile, we'd deeply appreciate any feedback, and happy to answer any questions here or on our slack channel. Thanks! April 29, 2021 at 07:50AM