Previously we built an OpenCV image based on Ubuntu Precise (12.04). Recently we created a new image based on Ubuntu Trusty (14.04). The following documented the steps.
# start a Ubuntu Trusty base image.
nova boot
# Associated a floating IP (204.188) from web UI.
# ssh in, update the packages.
sudo apt-get update
sudo apt-get dist-upgrade -y
sudo apt-get install python-pip -y # To install "pip".
sudo pip install pika # got 0.9.14.
sudo pip install python-numpy # Got 1:1.8.2-0ubuntu0.1.
# Added multiverse and USA archives in /etc/apt/sources.list.d/.
sudo apt-get update
sudo apt-get install libopencv-dev python-opencv # Got 2.4.8.
# http://milq.github.io/install-opencv-ubuntu-debian/
# http://stackoverflow.com/questions/25215102/installing-opencv-for-python-on-ubuntu-getting-importerror-no-module-named-cv2
sudo apt-get install git -y # 1.9.1.
sudo adduser --system medici
cd /home/medici
sudo git clone https://opensource.ncsa.illinois.edu/stash/scm/mmdb/extractors-cv.git
cd opencv/opencv-faces/
sudo cp -p config.py config.py.0
# Change rabbitmqURL, and the OpenCV xml file path.
sudo vi config.py
sudo sed -i -e 's|/usr/local/share/OpenCV/|/usr/share/opencv/|g' config.py
ls /usr/share/opencv/haarcascades/haarcascade_frontalface_alt.xml
sudo ln -s ../../../../pymedici .
sudo chown -R --reference=/home/medici /home/medici
# Change to Central Time.
sudo cp -p /usr/share/zoneinfo/US/Central /etc/localtime
# Added the upstart service conf files to /etc/init/.
Tested with dts-dev. First stopped extractor-0018, so only this VM has the 4 OpenCV extractors, then ran "tests.py" on dts-dev. All passed.