%title: Kubeception %author: @dghubble
// Youtube: https://www.youtube.com/watch?v=tlUiQa2JYQU
-> Experiments with QEMU/KVM on Kubernetes <-
%title: Kubeception %author: @dghubble
// Youtube: https://www.youtube.com/watch?v=tlUiQa2JYQU
-> Experiments with QEMU/KVM on Kubernetes <-
Run this in order to backup all you k8s cluster data. It will be saved in a folder bkp. To restore the cluster, you can run kubectl apply -f bkp
.
Please note: this recovers all resources correctly, including dynamically generated PV's. However, it will not recover ELB endpoints. You will need to update any DNS entries manually, and manually remove the old ELB's.
Please note: This has not been tested with all resource types. Supported resource types include:
import IPython.ipapi | |
from getpass import getpass | |
from netrc import netrc | |
from optparse import OptionParser | |
from google.appengine.ext.remote_api import remote_api_stub | |
from google.appengine.tools.appcfg import AppCfgApp, StatusUpdate | |
from google.appengine.tools.bulkloader import RequestManager |
#!/bin/bash | |
target_ip=`gethostip -d $1` | |
function is_local() { | |
echo $1 | grep '\(10\.\|127\.\|172\.\)' | |
} | |
flag=`is_local "$target_ip"` | |
if [ -n "$flag" ]; then |
PS1="$_OLD_VIRTUAL_PS1" | |
export PS1 | |
unset _OLD_VIRTUAL_PS1 | |
rehash |
#!/bin/zsh | |
scratchpad="scratch$1" | |
if tmux has -t $scratchpad; then | |
tmux attach -t $scratchpad | |
else | |
tmux new -s $scratchpad | |
fi |
ifconfig eth0:fakenfs <dead nfs server> netmask 255.255.255.255 | |
umount -f /nfs/... | |
ifconfig eth0:fakenfs down |
#!/bin/bash | |
# this allows to dump clear-text form of the exchanges between SSL client and SSL server | |
# client-side verification has to be disabled of course | |
# anyway, useful for debugging | |
# to run this you'll need | |
# - a unix system | |
# - socat | |
# - ncat (part of nmap 5.0 suite) |
keycode 0x12 = 9 bracketleft | |
keycode 0x13 = 0 bracketright | |
keycode 0x22 = parenleft braceleft | |
keycode 0x23 = parenright braceright | |
remove Lock = Caps_Lock | |
remove Control = Control_L | |
remove Control = Control_R | |
remove Mod2 = Num_Lock |