GithubHelp home page GithubHelp logo

th3architect / coreos-kubernetes-digitalocean Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bketelsen/coreos-kubernetes-digitalocean

0.0 1.0 0.0 271 KB

Configuration for running Kubernetes/CoreOS/Rudder on Digital Ocean

License: MIT License

coreos-kubernetes-digitalocean's Introduction

coreos-kubernetes-digitalocean

Configuration for running Kubernetes/CoreOS/Rudder on Digital Ocean

Use this guide to get a Kubernetes cluster running on CoreOS linux on your Digital Ocean account.

This guide is far from perfect, and can be probably be improved/automated quite a bit. Please send pull requests for corrections, clarifications and omissions.

Step 1

You're going to need a Digital Ocean account. If you don't have one, click here and use my referral link to get you (and me!) some free credit on Digital Ocean. I host all the Gopher Academy and GopherCon sites on Digital Ocean, so your referral credits will be put to good use.

Step 2

Follow this guide to install a three node CoreOS Cluster on Digital Ocean. I named my servers "master", "minion1" and "minion2" instead of the recommended "coreos-1", "coreos-2", and "coreos-3" so that I would remember which machines had which responsibilities.

Step 3

Go to the Digital Ocean control panel and write down the public and private IP addresses of all three machines.

Yours might look like this:

Machine Name Public IP Private IP
master 104.131.x.1 10.132.x.1
minion1 104.131.x.2 10.132.x.1
minion2 104.131.x.3 10.132.x.1

Step 4

Install Flannel so that each pod in the Kubernetes cluster can have it's own IP address.

On one of the CoreOS machines, checkout the Rudder source and follow the instructions to use their docker container to build Rudder.

When you're done you should have Rudder installed at /opt/bin/rudder

Step 5

Configure Rudder on each machine.

In /etc/systemd/system on each CoreOS machine, create a service file for rudder. Use this one as a template. Replace the line IP address my template with the correct PRIVATE IP address for that machine. Remember you can get that by typing ifconfig. My private IP addresses were on eth1.

Repeat this process for all three machines, ensuring that you use each machine's private ip address in the rudder.service file.

Add the service to systemctl: sudo systemctl enable /etc/systemd/system/rudder.service

Reload systemctl: sudo systemctl daemon-reload

Start Rudder: sudo systemctl start rudder

Step 6

Follow this same pattern to add docker, kubelet, and proxy services to all three machines. Remember to use YOUR private IP address in the kubelet.service file. Add each service, reload systemctl and start each service.

Step 7

On the master, add apiserver and controller-manager. In the apiserver.service file, list the private IP addresses of all three CoreOS machines on Line 15

*** Important - you need to add a scheduler service now, too. I'll try to add a service unit for this shortly. ***

Step 8

Download kubecfg pre-built binaries by following the instructions at the bottom of Kelsey Hightower's Guide I put mine in /opt/bin

With any luck you'll now have a fully operational Kubernetes cluster running on Digital Ocean. To test it type kubecfg list minions. You should see all three private ip addresses of your cluster listed in the result.

Thanks/Credit

I couldn't have gotten the cluster running without lots of debugging help from Kelsey Hightower. I also drew a lot of inspriation from this post

coreos-kubernetes-digitalocean's People

Contributors

acrmp avatar andrewmichaelsmith avatar bketelsen avatar

Watchers

 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.