I was looking to add running kubernetes jobs to a python cli I am creating, and I found this solution, mostly thanks to ollama run mistral:7b-instruct-q4_K_M and my loose understanding of what the yaml syntax is supposed to look like for a kubernetes job. This will let me create a job in the cluster, choose the image that runs, the command that is called, and how long until the job expires and is cleaned up. While the job still exists I can go in and look at the logs, but once its ttl has expired they are gone.
GitHub Stars
GitHub stars posts
Check out kevinhwang91 and their project nvim-ufo.
Not UFO in the sky, but an ultra fold in Neovim.
Clear out lsp diagnostics in nvim.
Iβve often struggled to find and kill a process using a certain port on archlinux. Mainly becuase most guides use netstat rather than ss.
Here is how I just killed the process using port 5000 using fuser.
sudo fuser -k 5000/tcp
You can also get information about the process by running lsof
This is a sick kubernetes architecture diagran generation tool.
Here is an example
I think just, might just be the thing I have been looking for. Iβve been looking for some ci/cd that I can host myself, but everything looks pretty big, so for now I am going to use just as my task runner.
I installed with installer.
curl https://i.wayl.one/casey/just | bash
I set up my devtainer builds with just. Here is my justfile, yes you just need the cli and a file named justfile.
kompose is a sick cli to convert docker-compose.yml to kubernetes manifest.
Running your own docker registry in one line
Example of how to add a pvc to a deployment.
I was curious to see what was going on inside of my minio object storage. Great technique here by Frank to create an inspector pod, then you can do as you wish with the data.
I created the manifest as pvc-inspector.yml
apiVersion: v1 kind: Pod metadata: name: pvc-inspector spec: containers: - image: busybox name: pvc-inspector command: ["tail"] args: ["-f", "/dev/null"] volumeMounts: - mountPath: /pvc name: pvc-mount volumes: - name: pvc-mount persistentVolumeClaim: claimName: pvc-name
Then used it like this.
In order to use k8s secrets manifest you first need to encode the data values.
Right after installing k3s you are going to need to use sudo to use any kubectl command. The reason for this is that the default config is owned by root. To get around this you will need to make your own config and set the KUBECONFIG environment variable
To do this I used sudo one last time to copy the k3s.yaml file into my own directory and take ownership of it.
I recently spun up k3s in my homelab. Iβm trying to offload some work off of my free tier fly.io app in order to keep it free tier without crashing.
# install and start k3s curl -sfL https://get.k3s.io | sh - # check to see if your nodes are started sudo kubectl get nodes
My main hiccup so far was the machine I am running on runs zfs on root, and it would not start the master node. Rather than figuring out how to make zfs play nice I just pointed k3s to a drive that is not zfs.
Check out djmaze and their project docker-caching-proxy.
Caching proxy docker image
Tailwind comes with space that I have never heard of that is made to give margin and padding together in one class. Adam dropped it here in the Tailwind Connect conference.
Litestar is an interesting api framework similar to fastpi, that I am interested to check out to see if it fits into some project scope. It sounds like it comes with a lot more batteries included for things like auth, but does not have hard opinions like django. At this point Iβm not jumping off of fastapi, but its something I want to try.
Deleting a fly postgres db cluster was not straightforward to me as the app name is not inferred from the toml like it is for the main app.
![[None]]
Yet again twitter cards were causing me pain. This time it was me not realizing that they require full urls, and not relative or abolute urls.
This was not working
<meta name="twitter:image" content="/shot/?path={{ request.url|quote_plus }}" content-type='image/png'/>
This does work with a full url