Docker and Kubernetes (b) build
Open Hyper-V
Installing Docker for Windows
Opened Kubernetes
3, key concepts
Pod
Kubernetes smallest unit, which can put a Pod many applications, to support multiple containers through the process in a communication Pod
Service service
outside the entrance Pod, you need to access outside the Pod
Deployment deployment
represents a user update operations on Kubernetes through the deployment template Pod with Service Binding
Rough understanding, can be deployed with Deployment Pod, and then exposed through access to the Pod Service.
Three types of Service
ClusterIP
an internal cluster service can not access the default external circumstances, you need to be forwarded through a proxy to access the command kubectl.
NodePort
open on all nodes in a particular port, the port forwards the traffic to the corresponding service, is exposed Pod method frequently used when developing, no proxy so much trouble.
LoadBalancer
Kubernetes load balancing, you need to load balancer (load balancer your cluster or cloud service providers) associated with it, it can help you to forward the traffic.
Configuration
4、 cd C:\docker
5, retrieve all contexts.
kubectl config get-contexts
6, specify the current context.
kubectl config use-context docker-for-desktop
7. Verify the cluster status
kubectl cluster-info
kubectl get nodes
8, installation Kubernetes Dashboard
:( a way to use the first)
kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/v1.10.1/src/deploy/recommended/kubernetes-dashboard.yaml
Second way (from before entering PS k8s-for-docker-desktop):
kubectl create -f kubernetes-dashboard.yaml
9, open API Server Access Proxy
kubectl proxy
10, open the browser to access Kubernetes Dashboard
http://localhost:8001/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy/#!/overview?namespace=default
10, the token acquisition token
kubectl -n kube-system describe secret default