The repository includes image-specifications (for docker currently) and yaml manifests for openshift to run oVirt deployment (oVirt-Engine and oVirt-Node).
Must use oc tool version 1.5.0 - https://github.com/openshift/origin/releases
WARNING |
---|
origin-clients rpm installation adds to /bin oc binary that might be older - verify that you work with 1.5 by "oc version" |
There are two options - running a cluster of openshift locally or using Minishift VM:
Minishift is a VM running openshift cluster in it. This mostly being used for testing for easy and quicker deployment without changing local environemnt
-
Install minishift - https://github.com/minishift/minishift
Since we are going to run VMs inside the minishift VM, it will need nested virtualization support. Minishift documentation suggests to install docker-machine-driver-kvm v0.7.0 but this is not enough to get virtualization support and a more recent one is needed; the right instructions (assuming centos7) to get it are:
curl -L https://github.com/docker/machine/releases/download/v0.11.0/docker-machine-`uname -s`-`uname -m` >/tmp/docker-machine && chmod +x /tmp/docker-machine && sudo cp /tmp/docker-machine /usr/local/bin/docker-machine curl -L https://github.com/dhiltgen/docker-machine-kvm/releases/download/v0.10.0/docker-machine-driver-kvm-centos7 > /usr/local/bin/docker-machine-driver-kvm && chmod +x /usr/local/bin/docker-machine-driver-kvm
Nested virtualization support is required on your physical system, please check it with:
cat /sys/module/kvm_intel/parameters/nested Y
If nested virtualization is not supported, please check your OS documentation about how to enable it.
-
Run the following
export OCTAG=v1.5.0 export PROJECT=ovirt export LATEST_MINISHIFT_CENTOS_ISO_BASE=$(curl -I https://github.com/minishift/minishift-centos-iso/releases/latest | grep "Location" | cut -d: -f2- | tr -d '\r' | xargs) export MINISHIFT_CENTOS_ISO=${LATEST_MINISHIFT_CENTOS_ISO_BASE/tag/download}/minishift-centos7.iso minishift start --memory 6144 --cpus 4 --iso-url=$MINISHIFT_CENTOS_ISO --openshift-version=$OCTAG export PATH=$PATH:~/.minishift/cache/oc/$OCTAG
Just follow https://github.com/openshift/origin/blob/master/docs/cluster_up_down.md#linux
oc login -u system:admin
export PROJECT=ovirt
oc new-project $PROJECT --description="oVirt" --display-name="oVirt"
oc adm policy add-role-to-user admin developer -n $PROJECT
Allows the usage of root account inside engine pod
oc create serviceaccount useroot
oc adm policy add-scc-to-user anyuid -z useroot
oc create serviceaccount privilegeduser
oc adm policy add-scc-to-user privileged -z privilegeduser
Please note that the engine deployment is configured as paused
oc create -f os-manifests -R
oc create -f os-manifests/engine -R
oc create -f os-manifests/vdsc -R
According to the hostname that was assigned to the associated route
oc set env dc/ovirt-engine -c ovirt-engine OVIRT_FQDN=$(oc describe routes ovirt-engine | grep "Requested Host:" | cut -d: -f2 | xargs)
oc set env dc/ovirt-engine -c ovirt-engine SPICE_PROXY=http://$(oc describe routes ovirt-spice-proxy | grep "Requested Host:" | cut -d: -f2 | xargs):3128
oc patch dc/ovirt-engine --patch '{"spec":{"paused": false}}'
Now you should be able to login as developer user (developer:admin) to the