Skip to content

Instantly share code, notes, and snippets.

View langburd's full-sized avatar

Avi Langburd langburd

View GitHub Profile
@langburd
langburd / k8s_service.py
Last active March 26, 2024 20:43
Kubernetes service to expose deployed image tag as Prometheus metrics
"""Kubernetes service to expose deployed image tag as Prometheus metrics."""
import os
from flask import Flask, Response
from kubernetes import client, config
from prometheus_client import CollectorRegistry, Gauge, generate_latest
app = Flask(__name__)
@langburd
langburd / cert_kubelet_renew.yml
Last active May 21, 2024 18:43
An Ansible playbook for manually updating certificates used by some K8S components installed with Kubespray. Valid for K8S version <1.16.
---
- name: Generate new kubelet certificates
hosts: k8s-cluster
gather_facts: true
serial: 1
vars:
valid_point_1: 10d
valid_point_2: 20d

Keybase proof

I hereby claim:

  • I am langburd on github.
  • I am langburd (https://keybase.io/langburd) on keybase.
  • I have a public key ASCskqVcvhZrIa3p0aIfCzbumsmq35PArs55F_6NVSIjyAo

To claim this, I am signing this object: