kubernetes minikube安裝

minikube安裝過程遇到的問題

1、國外鏡像拉取不下來問題
2、mac brew cask 安裝minikube
3、windows powerShell choco 安裝minkube

安裝homebrew

1、安裝homebrew文件
cd ~
curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install >> brew_install

另外一種形式:/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

卸載:/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"
2、更改腳本中的資源鏈接,替換成中科大的鏡像,編輯brew_install文件
注釋掉BREW_REPO = "https://github.com/Homebrew/brew".freeze
修改為BREW_REPO = "https://mirrors.ustc.edu.cn/brew.git".freeze

3、/usr/bin/ruby brew_install
4、進(jìn)入下面的 Taps 目錄,clone homebrew-core
cd /usr/local/Homebrew/Library/Taps/homebrew
git clone https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git

5、把homebrew repo切換為清華鏡像
cd "(brew --repo)" git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git cd "(brew --repo)/Library/Taps/homebrew/homebrew-core"
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git
brew update

6、替換 Bottles 源
Homebrew Bottles是Homebrew提供的二進(jìn)制代碼包,目前鏡像站收錄了以下倉庫:

homebrew/homebrew-core

homebrew/homebrew-dupes

homebrew/homebrew-games

homebrew/homebrew-gui

homebrew/homebrew-python

homebrew/homebrew-php

homebrew/homebrew-science

homebrew/homebrew-versions

homebrew/homebrew-x11

替換方式如下

bash(默認(rèn) shell)用戶
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.ustc.edu.cn/homebrew-bottles' >> ~/.bash_profile
source ~/.bash_profile

對于zsh用戶
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.ustc.edu.cn/homebrew-bottles' >> ~/.zshrc
source ~/.zshrc

6、終端會顯示Already up-to-date.到此,homebrew就安裝完畢了

基礎(chǔ)命令:

1、vim /etc/profile(sudo vim /etc/profile)
export PATH=/usr/local/bin:$PATH
source /etc/profile

2、切換到root用戶的命令為 su -,從root用戶切換回普通用戶 su - test
3、chown、chmod
4、vim、vi
5、touch命令
一是用于把已存在文件的時間標(biāo)簽更新為系統(tǒng)當(dāng)前的時間(默認(rèn)方式),它們的數(shù)據(jù)將原封不動地保留下來;

二是用來創(chuàng)建新的空文件

brew命令

1、brew instlal kubectl
2、brew cask install minikube
3、brew doctor
4、brew search
5、brew update
6、brew version

HomeBrew 安裝軟件慢的解決方法(解決方法就是更換國內(nèi)鏡像源):

homebrew 默認(rèn)的源是在 github 上面,每次更新速度都會非常慢。所以我們更換成國內(nèi)的鏡像源。就會快很多了
1、 git clone git://mirrors.ustc.edu.cn/homebrew-core.git/ /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core --depth=1
2、cd "$(brew --repo)"
git remote set-url origin https://mirrors.ustc.edu.cn/brew.git

cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"
git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.git

minikube安裝:

1、curl -Lo minikube http://kubernetes.oss-cn-hangzhou.aliyuncs.com/minikube/releases/v0.28.0/minikube-darwin-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/

minikube命令:

1、minikube version
2、minikube dashboard 啟動控制面板
3、minikube start --vm-driver=virtualbox
4、minikube stop
5、minikube status

windows choco安裝

1、cmd中輸入powershell
2、安裝VirtualBox

apt-get、yum、yarn

wget

linux

systemctl
service

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容