-
Notifications
You must be signed in to change notification settings - Fork 196
Installation: Virtual Box
For those users who do not want to build Karma from source code, we have vagrant - Running Karma in a virtual box.
- Download and Install vagrant - https://www.vagrantup.com/downloads.html Select the download package according to your Operating System and install vagrant.
- Download and Install Virtual Box - vagrant can work with a variety of virtual machine providers, for example: Virtual Box. Download and install the Virtual Box version according to your operating system from - https://www.virtualbox.org/wiki/Downloads
Please make sure that vbguest is installed (https://github.com/dotless-de/vagrant-vbguest/). It helps keep the VirtualBoxGuestAdditions up to date, install on the cmd line:
vagrant plugin install vagrant-vbguest
When starting this on Linux, do not use your distribution's Vagrant package to install vagrant. Install from https://www.vagrantup.com to ensure you're using the latest version of Vagrant. Using old versions of Vagrant will result in errors.
- If you are on a Mac or Linux machine, open a Terminal. For Windows, open Command Prompt.
- Navigate to your home directory, lets call it $HOME.The following steps will create a directory called Web-Karma in your home directory.
- Type the commands until Step 6 in your Terminal or Command Prompt;
git clone https://github.com/usc-isi-i2/Web-Karma.git
This will create a directory called Web-Karma -
cd Web-Karma/vagrant
Navigate to the folder vagrant -
vagrant up
This will boot the Virtual Machine, compile Karma and bring up the web server for Karma. For the first this step takes about 5-10 minutes to set the virtual machine. - After you see a message like
==> default: Initialized empty Git repository in /home/vagrant/Web-Karma/.git/
==> default: Running provisioner: shell...
default: Running: /tmp/vagrant-shell20151027-3166-1agb82o.sh
Open http://localhost:8080 in a browser
-
Halting the virtual machine by calling
vagrant halt
will gracefully shut down the guest operating system and power down the guest machine. You can usevagrant up
when you're ready to boot it again. The benefit of this method is that it will cleanly shut down your machine, preserving the contents of disk, and allowing it to be cleanly started again. The downside is that it'll take some extra time to start from a cold boot, and the guest machine still consumes disk space. - If you want to completely remove karma vagrant from your machine, running
vagrant destroy
will remove all traces of the guest machine from your system. It'll stop the guest machine, power it down, and remove all of the guest hard disks. Again, when you're ready to work again, just issue a vagrant up. The benefit of this is that no cruft is left on your machine. The disk space and RAM consumed by the guest machine is reclaimed and your host machine is left clean. The downside is thatvagrant up
to get working again will take some extra time since it has to reimport the machine and re provision it.
You have to call all the vagrant commands from within the $HOME/Web-Karma/vagrant folder
By default, the karma folder in Web-Karma/vagrant is set as KARMA_HOME. To use a custom karma home, copy your karma folder to Web-Karma/vagrant.
Warning: Karma home cannot be changed from the GUI.