Running the latest ResourceSpace in 5 minutes on Vagrant

I recently started to fix some issues with the Smart Keywording ResourceSpace plugin and the latest ResourceSpace. Since I need a running ResourceSpace to test the plugin, and because I also need a fresh ResourceSpace sometimes to check whether everything installs correctly or to test a specific version, I built a configuration for Vagrant that allows me to boot up a fresh installation of ResourceSpace within 5 minutes. Fresh means really fresh, i.e., no data, latest commit from trunk, perfect for development and testing. But Vagrant also allows me to keep the state of a virtual machine until I explicitly destroy it. And I can have different versions of the virtual machine. If I modify the configuration to map different ports, they can even run in parallel.

I encourage you to checkout Vagrant, which seems to be great for having dedicated, small VMs for development and testing.

You can find the Vagrant configuration at github.

2 thoughts on “Running the latest ResourceSpace in 5 minutes on Vagrant

  1. alain marcel

    Hi Carsten
    I have read your great article about OSGi to Akka at

    I am developing with scala and akka and use ScalaTest for unit tests and integration tests.
    I use eclipse, with one workspace and several projects. I do not use OSGi.
    Projects are organized in SBT “style” (that corresponds to Maven “style””).

    My next goal is to automate the whole life cycle :
    – compilation (I know to do that with sbt compile and sbt publishLocal)
    – unit test (I know to do that with sbt)
    – packaging
    – integration test

    Before doing that
    – I have made a training of four days to learn OSGi, eclipse 4, and maven tycho…
    – I have made some SBT scripts to compile and unit test projects: ok
    – I have tried Hudson.

    Given my first OSGi approach and your article, I think I will try to continue with SBT.
    Could you please give me some advice ?

    To simplify, projects can be seen in the eclipse workspace as
    – Lib1
    – Contains only code in src/main/scala
    – Lib2 that depends on Lib1
    – Contains only code in src/main/scala
    – App1 that depends on Lib2
    – Contains code in src/main/scala and distribution files under src/main/assembly
    – TesterApp that depends on Lib2, used for integration test
    – Contains code in src/main/scala and distribution files under src/main/assembly

    Currently, the distribution for integration test is under App1/src/test/assembly
    I put manually
    – App1 distribution
    – TesterApp distribution
    I start manually the integration tests suite.

    Question : how to organize automatisation for integration test ?

    Ideas :
    I think I have to
    – “sbt publishLocal” Lib1
    – “sbt publishLocal” Lib2
    – “sbt publishLocal” App1
    – “sbr publishLocal” TesterApp
    After, I don’t know how to process.

    Very thanks for any help.
    Best regards,

  2. Carsten Saathoff Post author


    you will need Hudson or Jenkins (I prefer the latter), and install the sbt plugin. Your unit tests are executed using sbt, so the build will fail when they contain errors. If you want to have integration tests, I would either have a sbt project that runs the integration tests as part of the test stage, and the same approach as for the unit tests will work. Or you write a script that exits with a non zero exit code, when any of the test fail, and the build server will mark that project as failed also. What the best approach is depends on many factors, e.g., your environment, your preferences, your project, the involved technologies, etc. It’s impossible to give you general advice on how to do it right.

Leave a Reply

Your email address will not be published. Required fields are marked *

To create code blocks or other preformatted text, indent by four spaces:

    This will be displayed in a monospaced font. The first four 
    spaces will be stripped off, but all other whitespace
    will be preserved.
    Markdown is turned off in code blocks:
     [This is not a link](

To create not a block, but an inline code span, use backticks:

Here is some inline `code`.

For more help see