Skip to content

Instantly share code, notes, and snippets.

View lvangool's full-sized avatar

Vic van Gool lvangool

View GitHub Profile
@lvangool
lvangool / sidekiq_safe_shutdown.rb
Last active July 30, 2024 13:21
Kubernetes: Graceful Sidekiq Shutdown
#! /usr/bin/env ruby
# encoding: utf-8
## PURPOSE: this script will quiet any sidekiq workers it finds,
## and then shut them down when they are no longer handling jobs
# utility class for logging and running commands
class Utils
require 'open3'
attr_accessor :output
@lvangool
lvangool / kubedump.sh
Last active September 15, 2020 09:18 — forked from negz/kubedump.sh
Dump Kubernetes cluster resources as YAML
#!/usr/bin/env bash
set -e
CONTEXT="$1"
if [[ -z ${CONTEXT} ]]; then
echo "Usage: $0 KUBE-CONTEXT"
exit 1
fi