rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
yum install -y http://www.elrepo.org/elrepo-release-7.0-2.el7.elrepo.noarch.rpm
yum-config-manager --enable elrepo-kernel
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
# Please note, the commands below will create unreadable files and should be | |
# used for testing file size only. If you're looking for something that has | |
# lines in it, use /dev/urandom instead of /dev/zero. You'll then be able to | |
# read the number of lines in that file using `wc -l large-file.1mb.txt` | |
# Create a 1MB file | |
dd if=/dev/zero of=large-file-1mb.txt count=1024 bs=1024 | |
# Create a 10MB file | |
dd if=/dev/zero of=large-file-10mb.txt count=1024 bs=10240 |
kind: Ingress | |
apiVersion: extensions/v1beta1 | |
metadata: | |
name: redirect-ingress | |
annotations: | |
ingress.kubernetes.io/configuration-snippet: | | |
if ($host ~ ^(.+)\.somedomain\.io$) { | |
return 301 https://$1.domain.io$request_uri; | |
} | |
spec: |
# based on the "patch deployment" strategy in this comment: | |
# https://github.com/kubernetes/kubernetes/issues/13488#issuecomment-372532659 | |
# requires jq | |
# $1 is a valid namespace | |
function refresh-all-pods() { | |
echo | |
DEPLOYMENT_LIST=$(kubectl -n $1 get deployment -o json|jq -r .items[].metadata.name) | |
echo "Refreshing pods in all Deployments" | |
for deployment_name in $DEPLOYMENT_LIST ; do |
# https://medium.com/@eduardobaitello/using-different-kubectl-versions-with-multiple-kubernetes-clusters-a3ad8707b87b | |
# Pssssst..Ubuntu here... | |
# Configuring kube_ps1 on PS1 | |
if [ "$color_prompt" = yes ]; then | |
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]$(kube_ps1)\$ ' | |
else | |
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w$(kube_ps1)\$ ' | |
fi | |
unset color_prompt force_color_prompt |
coreDns: | |
service: | |
selector: | |
k8s-app: kube-dns | |
kubeControllerManager: | |
service: | |
selector: | |
k8s-app: null | |
component: kube-controller-manager | |
kubeEtcd: |