GithubHelp home page GithubHelp logo

huangu0 / ansible-kubernetes Goto Github PK

View Code? Open in Web Editor NEW

This project forked from chinacloud/ansible-kubernetes

0.0 3.0 0.0 52.95 MB

Ansible离线部署Kubernetes集群.

License: Apache License 2.0

Roff 33.59% Shell 66.41%

ansible-kubernetes's Introduction

Ansible离线部署Kubernetes集群

目前仅在centos7系统上测试通过.

通过Ansible部署Kubernetes集群至物理机/虚拟机. 已内置Kubernetes运行所需的可执行文件, 如: Docker安装文件、Etcd可执行文件、Flannel可执行文件等, 部署过程全自动, 并且无需访问因特网.

由于一些内置文件比较大, 您需要安装Git LFS拓展, 以下载本仓库, 详见: https://git-lfs.github.com

默认部署软件版本:

软件 版本
Docker Engine v1.11.2
Docker Registry v2.0
Etcd v2.3.7
Flannel v0.5.3
Kubernetes v1.3.7

您也可以下载其他版本的可运行文件放置到指定目录中, 通过Ansible变量指定部署其他Kubernetes或依赖软件版本.

概览

准备

快速开始

技巧提示

  • 除了以上可以单步执行部署步骤以外,还可以一键部署,如下:
$ cat ./all-in-one.yml

# Step 1, 关闭防火墙, 安装Docker
- include: base.yml
# Step 2, 安装容器镜像仓库
- include: registry.yml
# Step 3, 部署Etcd集群
- include: etcd.yml
# Step 4, 部署Kubernetes ssh安全配置
- include: k8s-ssh.yml
# Step 5, 部署Kubernetes Master节点
- include: masters.yml
# Step 6, 部署Kubernetes Minion节点
- include: minions.yml

以上步骤将会从上到下依次执行,你也可以根据需要在此文件中修改

已知问题

  • 配置k8s-ssh认证服务的时候,执行脚init-ca-ssl.sh和init-ssl.sh可能会报错, 可能的原因:

    1. 因为上传的时候造成了脚本格式错乱,因此,你可以利用dos2unix工具格式化脚本

    2. ssh登陆不上,重新验证ssh-keygen无秘钥登陆

  • 最好使用docker 1.11版本,因为在docker 1.12中有时候会出现pause容器不能运行的现象

贡献者

按加入项目时间先后顺序排序

开源协议

ansible-k8s基于Apache License Version 2.0发布(ansible-k8s is released under the Apache License Version 2.0).

ansible-kubernetes's People

Contributors

taoyu27 avatar xuwenbao avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.