GithubHelp home page GithubHelp logo

williamjoye / openshift-vagrant Goto Github PK

View Code? Open in Web Editor NEW

This project forked from yylin1/openshift-vagrant

0.0 0.0 0.0 53 KB

Bring up a real OKD cluster on your local machine using Vagrant and VirtualBox

License: Apache License 2.0

Shell 100.00%

openshift-vagrant's Introduction

OpenShift Vagrant

Licensed under Apache License version 2.0

Overview

The OpenShift Vagrant project aims to make it easy to bring up a real OKD cluster by provisioning pre-configured Vagrantfile of several major releases of OKD on your local machine.

Prerequisites

  • Host machine must have at least 4GB memory
  • Oracle VirtualBox installed on your host machine
  • Vagrant (2.0 or above) installed on your host machine
  • Vagrant plugin vagrant-hostmanager must be installed

OKD Version Support

Currently this project pre-configured and support 3 major versions of the OKD, which are

But, it's very easy to customize the respected ansible hosts file in order to support other incoming major versions.

The Vagrantfile uses Origin 3.10 and openshift-ansible release-3.10 branch by default. Feel free to adjust your versions by updating the following 2 variables in Vagrantfile:

  1. OPENSHIFT_RELEASE
  2. OPENSHIFT_ANSIBLE_BRANCH

The following table lists the corresponding version relationships between Origin and openshift-ansible:

OKD version openshift-ansible branch
3.11.x release-3.11
3.10.x release-3.10
3.9.x release-3.9
3.7.x release-3.7
3.6.x release-3.6

Getting Started

After adjusting your expected version information, now it's time to bring your cluster up and running.

This Vagrantfile will create 3 VMs in VirtualBox and the network base will be specified by variable NETWORK_BASE.

Checkout the table below for more details:

VM Node Private IP Roles
master #{NETWORK_BASE}.101 node, master, etcd
node01 #{NETWORK_BASE}.102 node
node02 #{NETWORK_BASE}.103 node

Bring Vagrant Up

$ vagrant up

Provisioning Private Keys

$ vagrant provision --provision-with master-key,node01-key,node02-key

Install Origin Cluster Using Ansible

Run the following command if you would like to install origin previous to release-3.8:

$ vagrant ssh master -c 'ansible-playbook /home/vagrant/openshift-ansible/playbooks/byo/config.yml'

Run the following command for origin 3.8 or above:

vagrant ssh master \
        -c 'ansible-playbook /home/vagrant/openshift-ansible/playbooks/prerequisites.yml &&
            ansible-playbook /home/vagrant/openshift-ansible/playbooks/deploy_cluster.yml'

oc-up.sh

The above 3 steps have been grouped together as one script for you. To bring your cluster up, just use the following command:

$ ./oc-up.sh

Open Web Console

In browser of your host, open the following page: https://master.example.com:8443/ and you should see OpenShift Web Console login page. The default login account is admin/handhand

Have fun with OKD and Vagrant :p

openshift-vagrant's People

Contributors

eliu 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.