在ubuntu上安装kubernetes
来源:互联网 发布:mac视频播放器推荐 编辑:程序博客网 时间:2024/05/16 08:44
安装环境:
- Linux (自用ubuntu14.04)
- Docker 1.3+
- go 1.3+
- etcd
安装
从github上下载源码
$ git clone https://github.com/kubernetes/kubernetes.git$ cd kubernetes有两种安装方法,二选其一,前者方便快捷,后者因要运行测试等,花费时间较长。1.Build just linux binaries in the container. Pass options and packages as necessary$ hack/build-go.sh2.Build everything, test it, and (optionally) upload the results to a GCS bucket$ build/release.sh$ cp _output/dockerized/bin/linux/amd64/kube* /usr/bin查看安装情况$ kubectl version提示[root@root]# Client Version: version.Info{Major:"1", Minor:"2+", GitVersion:"v1.2.0-alpha.8.693+5b415a7aede533", GitCommit:"5b415a7aede5338595b06e4f4625736b18c185e3", GitTreeState:"clean"}[root@root]# error: couldn't read version from server: Get http://localhost:8080/api: dial tcp 127.0.0.1:8080: connection refused安装成功,只是没启动cluster
Starting the cluster
$ cd kubernetes$ hack/local-up-cluster.sh
之后你在运行kubectl version
[root@root]# Client Version: version.Info{Major:"1", Minor:"2+", GitVersion:"v1.2.0-alpha.8.693+5b415a7aede533", GitCommit:"5b415a7aede5338595b06e4f4625736b18c185e3", GitTreeState:"clean"}[root@root]# Server Version: version.Info{Major:"1", Minor:"2+", GitVersion:"v1.2.0-alpha.8.693+5b415a7aede533", GitCommit:"5b415a7aede5338595b06e4f4625736b18c185e3", GitTreeState:"clean"}
启动一个容器
$ cluster/kubectl.sh get pods$ cluster/kubectl.sh get services$ cluster/kubectl.sh get replicationcontrollers$ cluster/kubectl.sh run my-nginx --image=nginx --replicas=2 --port=80## begin wait for provision to complete, you can monitor the docker pull by opening a new terminal $ sudo docker images## you should see it pulling the nginx image, once the above command returns it $ sudo docker ps## you should see your container running! $ exit## end wait
0 0
- 在ubuntu上安装kubernetes
- 在ubuntu上Kubernetes集群部署
- Ubuntu 14.04 安装kubernetes
- 在RHEL 7上安装和配置kubernetes
- Centos7.2 Kubernetes 集群在centos 上安装步骤
- ubuntu安装单机版kubernetes
- Ubuntu上手动安装Kubernetes
- ubuntu多节点安装kubernetes
- 在centos7上部署kubernetes
- 在centos7上部署kubernetes
- 在centos7上部署kubernetes
- 在Ubuntu上安装Ruby
- 在Ubuntu上安装SVN
- 在Ubuntu上安装PostgreSQL
- 在Ubuntu上安装VNC
- 在Ubuntu上安装openssh
- 在ubuntu上安装trac
- 在Ubuntu上安装Ruby
- Java中的静态内部类与非静态内部类的区别
- 设计模式(10)——组合模式(Composite Pattern)
- Centos 6.7 下安装git 各种累心折腾
- iOS开发学习_OC基础_(一).类、对象和方法(1)
- 聚焦Web设计
- 在ubuntu上安装kubernetes
- Xcode 打印中文结果
- 设计模式(11)——外观模式(Facade Pattern)
- eclipse调试java程序的九个技巧
- 第3章 洞察他人内心的心理策略
- 利用压缩软件制作插件安装包
- for循环中的分批提交到数据库代码
- 从HashMap到LruCache的源码分析
- 设计模式(12)——享元模式(Flyweight Pattern)