Skip to content

Instantly share code, notes, and snippets.

View KozhevnikovM's full-sized avatar

Mikhail Kozhevnikov KozhevnikovM

View GitHub Profile
@souzaxx
souzaxx / ENIConfig.yaml
Last active June 21, 2023 06:46
An example using terraform templatefile with Helm
{{- range .Values.zones }}
---
apiVersion: crd.k8s.amazonaws.com/v1alpha1
kind: ENIConfig
metadata:
name: {{ .name }}
spec:
subnet: {{ .subnetID }}
securityGroups:
{{- range $.Values.securityGroupIDs }}
@mousavian
mousavian / k8s-cronjob-suspend.sh
Last active September 15, 2023 08:40
Suspending all cronjobs in all namespaces in kubernetes
#!/bin/bash
for ns in $(kubectl get ns -o jsonpath="{.items[*].metadata.name}"); do
for cj in $(kubectl get cronjobs -n "$ns" -o name); do
kubectl patch "$cj" -n "$ns" -p '{"spec" : {"suspend" : true }}';
done
done