Skip to content

Latest commit

 

History

History
99 lines (72 loc) · 4.23 KB

setup-environment.adoc

File metadata and controls

99 lines (72 loc) · 4.23 KB

Setup environment

Duration: 15:00

This section describes what, how, and where to install the software needed for this lab. This lab is designed for a BYOL (Bring Your Own Laptop) style hands-on-lab.

Hardware

  • Operating System: Windows 7 (SP1), Mac OS X (10.8 or later), Fedora (21 or later)

  • Memory: At least 4 GB+, preferred 8 GB

Software

Vagrant

Vagrant is a tool for building complete development environments. With an easy-to-use workflow and focus on automation, Vagrant lowers development environment setup time, increases development/production parity, and makes the "works on my machine" excuse a relic of the past.

Downloads are available from: https://releases.hashicorp.com/vagrant/

Warning

Do NOT use Vagrant 1.8.5 as it contains a bug that "slipped in". So what version should I (the reader) download? The older versions are under "Archives" https://releases.hashicorp.com/vagrant/

A virtualization platform (hypervisor) - VirtualBox 5.0.x

Vagrant needs a hypervisor to create a development environment.

Warning

You should use VirtualBox 5.0.x

Linux Users:

  1. Have your kernel updated

  2. Users should have the GNU compiler, build and header files for your current Linux kernel

  3. Create a /usr/src/linux link to the current kernel source

CDK

Red Hat Container Development Kit is a pre-built container development environment based on RHEL - Red Hat Enterprise Linux to help you get started developing container-based applications quickly.

Developers can get the Red Hat Container Development Kit via no-cost Red Hat Enterprise Linux® Developer Suite subscription for development purposes by registering and downloading through developers.redhat.com.

Important
Make sure to take notes of your username(email) and password. It will be used as the free subscription for RHEL.
Warning

Setup CDK:

  • Install Vagrant and VirtualBox

  • Install Vagrant plugins

  • Add Vagrant box with vagrant box command

  • Extract CDK

  • Start the environment with vagrant up

# From the Downloads folder (or any other folder)
Downloads$ vagrant box add --name cdkv2 <path of .box file>
Downloads$ unzip cdk-2.1.0.zip
Downloads$ cd cdk/components/rhel/rhel-ose
# From CDK extracted folder
rhel-ose$ vagrant plugin install vagrant-service-manager vagrant-registration
rhel-ose$ vagrant up
rhel-ose$ vagrant ssh
#Inside CDK shell - Create a Kubernetes context - We will use the OpenShift Client (oc) as as shortcut
[vagrant@rhel-cdk ~]$ oc login -u openshift-dev -p devel
Important
If you use an invalid username/password, you will need to destroy your VM using vagrant destroy and start it again.
Tip
TIP: If you have any failures, consult the Troubleshooting section. It might contain the solution that you look for.