This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This DaemonSet basically adds your id_rsa.pub to the authorized_keys on the EKS Worker Node EC2. | |
# Just save this as a yaml file, replace your public key below and run | |
# $ kubectl apply -f eks_node_add_public_key.yaml | |
# Check all the pods are running and as soon as they are running, you can remove the set: | |
# $ kubectl delete -f eks_node_add_public_key.yaml | |
# | |
apiVersion: apps/v1 | |
kind: DaemonSet | |
metadata: | |
labels: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# set prompt color to blue | |
CB=$'\e[35m' | |
CE=$'\e[0m' | |
es=$'\e' # read escape characters, $'\033' works too | |
back=$'\033[1D' # move curser back | |
eof=$'\004' # read end of file, Ctrl-D | |
tab=$'\t' | |
eol=$'\n' # end of line |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# pad base64URL encoded to base64 | |
paddit() { | |
input=$1 | |
l=`echo -n $input | wc -c` | |
while [ `expr $l % 4` -ne 0 ] | |
do | |
input="${input}=" | |
l=`echo -n $input | wc -c` |