Qiita Teams that are logged in
You are not logged in to any team

Log in to Qiita Team
Community
OrganizationAdvent CalendarQiitadon (β)
Service
Qiita JobsQiita ZineQiita Blog
Help us understand the problem. What is going on with this article?

OSX上にxhyveでminikubeを構築

More than 3 years have passed since last update.

OSX上にminikubeを構築した際のメモ
xhyveを使ったほうがVirtualBoxより軽快な動作かなと思ったので、xhyveを使ってます。

Versions

OSX 10.11.6
minikube v0.17.1

xhyveとは

https://github.com/mist64/xhyve
OSX用のHypervisor。
VirtualBoxより動作が軽快?

Install xhyve driver

公式から引用 https://github.com/kubernetes/minikube/blob/master/DRIVERS.md#xhyve-driver

$ brew install docker-machine-driver-xhyve

# docker-machine-driver-xhyve need root owner and uid
$ sudo chown root:wheel $(brew --prefix)/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve
$ sudo chmod u+s $(brew --prefix)/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve

Install Kubernetes

公式から引用 https://kubernetes.io/docs/tasks/kubectl/install/

curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/darwin/amd64/kubectl

Install minikube

curl -Lo minikube https://storage.googleapis.com/minikube/releases/v0.17.1/minikube-darwin-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/

Start minikube

--vm-driverでxhyveを指定

minikube start --vm-driver=xhyve

get nodes

get nodesをしてminikubeが動いているかを確認します。

kubectl get nodes

動いていれば下記のような結果が出力されるはずです。

NAME       STATUS    AGE
minikube   Ready     23h
tinjyuu
今では珍しくない珍獣です。
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away