Skip to content
Henri edited this page Mar 31, 2014 · 7 revisions

Vagrant box

The easiest way to develop in Opa on most platforms is to use a vagrant box. Install vagrant (and VirtualBox on some platforms).

Download the opa box torrent and run

vagrant box add opa opa.box
mkdir opa
cd opa
vagrant init opa

The box is a linux system running in a VM that contains a pre-built Opa system with all dependencies. Once the box is created, run:

vagrant up
vagrant ssh

to start the VM and log into it. Opa is installed and in user path, so you can just run

opa file.opa
./file.js

to compile and run an Opa program. Note that tutorials are preinstalled in your home directory.

If you're new to vagrant, note that the host directory is mounted under /vagrant in the VM, so you can leave Opa programs in your host and just keep a console in the VM to compile and run your apps.