Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Remove clone OOM project as it is not necessary

...

#PurposeCommand and Example
1

Add host name to /etc/hosts file

note-1

sudo vi /etc/hosts

Expand
titleExample result of /etc/hosts file

$ more /etc/hosts

127.0.0.1 sdnc-k8s localhost

...

10.147.132.10 sdnc-k8s

10.147.90.6 sdnc-k8s-2

Clone the OOM project from ONAP gerrit

git clone http://gerrit.onap.org/r/oom

Install Docker 1.12

note-2


curl https://releases.rancher.com/install-docker/1.12.sh | sh

Expand
titleExample of docker installation

$ curl https://releases.rancher.com/install-docker/1.12.sh | sh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 16609 100 16609 0 0 18977 0 --:--:-- --:--:-- --:--:-- 18960
apparmor is enabled in the kernel and apparmor utils were already installed
+ sudo -E sh -c sleep 3; apt-get update

...

+ sudo -E sh -c docker version
Client:
Version: 1.12.6
API version: 1.24
Go version: go1.6.4
Git commit: 78d1802
Built: Tue Jan 10 20:38:45 2017
OS/Arch: linux/amd64

Server:
Version: 1.12.6
API version: 1.24
Go version: go1.6.4
Git commit: 78d1802
Built: Tue Jan 10 20:38:45 2017
OS/Arch: linux/amd64

If you would like to use Docker as a non-root user, you should now consider
adding your user to the "docker" group with something like:

sudo usermod -aG docker ubuntu

Remember that you will have to log out and back in for this to take effect!

$

sudo usermod -aG docker ubuntu

logout

log back in and validate docker command is usable

Expand
titleAn example of validating docker command is usable

$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES

$
43

Install/Start Rancher server

note-3

Only on one node (if you are installing more than one Kubernetes nodes, choose one node to run the Rancher). Use port 8880 instead of 8080.

docker run -d --restart=unless-stopped -p 8880:8080 rancher/server:v1.6.10

Expand
titleExample of rancher start in docker


$ docker run -d --restart=unless-stopped -p 8880:8080 rancher/server:v1.6.10

Unable to find image 'rancher/server:latest' locally

latest: Pulling from rancher/server

6599cadaf950: Pull complete

23eda618d451: Pull complete

f0be3084efe9: Pull complete

52de432f084b: Pull complete

a3ed95caeb02: Pull complete

e75cd91a1dc5: Pull complete

997f1b48f59f: Pull complete

313c28fb4e37: Pull complete

2a0730d1275c: Pull complete

8848fbebd2c8: Pull complete

906504ea9ea6: Pull complete

9329940f8e65: Pull complete

e849debd7945: Pull complete

4883bd135dd2: Pull complete

605c6a0fe940: Pull complete

274bc004c933: Pull complete

a6cb25e8d1a2: Pull complete

3ded9d4c8c2b: Pull complete

a571d2f40012: Pull complete

Digest: sha256:096026aa3eed411077690c904cd5dd3cce66eb39312c78a84209eab23387c36d

Status: Downloaded newer image for rancher/server:latest

4b3020cfccc2db47905e89e66cd8533fea82d60b886b2f4509e5f1c56764563a

Expand
titleExample of validate rancher server is up in docker

$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
e3f1c2ce3234 rancher/server:v1.6.10 "/usr/bin/entry /usr/" 7 seconds ago Up 6 seconds 3306/tcp, 0.0.0.0:8880->8080/tcp pensive_goldberg
$


$ docker ps

CONTAINER ID    IMAGE               COMMAND                  CREATED             STATUS              PORTS                               NAMES

4b3020cfccc2        rancher/server      "/usr/bin/entry /usr/"   12 minutes ago      Up 12 minutes       3306/tcp, 0.0.0.0:8880->8080/tcp   backstabbing_wright

...