Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Rodolfo Casas rodolof

🏠
Working from home
  • Rodolfo Casas
View GitHub Profile
@rodolof
rodolof / regenerate-kubeconfig.sh
Created Oct 14, 2021 — forked from rcarrata/regenerate-kubeconfig.sh
Script for regenerating the kubeconfig for system:admin user
View regenerate-kubeconfig.sh
#!/bin/bash
AUTH_NAME="auth2kube"
NEW_KUBECONFIG="newkubeconfig"
echo "create a certificate request for system:admin user"
openssl req -new -newkey rsa:4096 -nodes -keyout $AUTH_NAME.key -out $AUTH_NAME.csr -subj "/CN=system:admin/O=system:masters"
echo "create signing request resource definition"