新增learn-kubernetes(https://github.com/yyong-brs/learn-kubernetes)相关文件
This commit is contained in:
17
learn/learn-kubernetes-master/kiamol/ch01/vagrant/kiamol.sh
Normal file
17
learn/learn-kubernetes-master/kiamol/ch01/vagrant/kiamol.sh
Normal file
@@ -0,0 +1,17 @@
|
||||
#!/bin/bash
|
||||
|
||||
echo '---------'
|
||||
echo "kiamol.sh as: $(whoami)"
|
||||
echo '---------'
|
||||
|
||||
# create the cluster
|
||||
mkdir -p ~/.kube
|
||||
sudo kind create cluster --image kindest/node:v1.18.8 --name kiamol --kubeconfig /home/vagrant/.kube/config
|
||||
sudo chown vagrant ~/.kube/config
|
||||
|
||||
# set MOTD
|
||||
sudo sh -c 'echo "\n** Learn Kubernetes in a Month of Lunches **\n** https://kiamol.net **\nSource is in /kiamol\nIf Kubectl does not respond, start the Kind container with:\n docker start kiamol-control-plane\n" > /etc/motd'
|
||||
|
||||
# add aliases:
|
||||
echo "alias k='kubectl'" >> ~/.bashrc
|
||||
echo "alias d='docker'" >> ~/.bashrc
|
||||
Reference in New Issue
Block a user