Quick Start Guide

OpenNaaS is open to the collaboration of new developers, companies, universities, which want to participate in the implementation to any degree of implication. If you want to build over it or just give it a try you can get the source code and built it youself. Check below for a quick setup guide.

Download source code

The source code of OpenNaaS is in the following GitHub repository: https://github.com/dana-i2cat/opennaas/

Master or Develop version

You will find the stable version on the default branch (master). It is usually only updated when there is a release. There is also another version called “develop”, a part from other branches, that you might want to download in case you need the latest version under development. We will suggest you to start with the master version.

Download from GitHub

You can download the code using different methods:

  1. Use the public repository link to clone the project with the command line (recommended)
  2. Clone it directly to your Desktop using GitHub desktop application
  3. Download a ZIP with the sourcecode (fastest)

GitHub_cap02

Option 1

As you probably plan to develop and contribute with your code (right?), let us suggest you to use the first option. You can get the source code from our public repository and build it from scratch, but you’ll need Maven 3 and Git installed.

Once you have both correctly setup, you can use the following command to download the source code. Open a command line, go to a directory of your choice and on Linux and Mac type:

git clone git://github.com/dana-i2cat/opennaas.git

For Windows, instructions vary on the client you are using (if you use GitBash, the command will be exactly as above). Just use the URL above with anonymous access. Github’s help section is an excellent resource with instructions for several platforms.

If you want to change to the latest develop version you need to use the “develop” branch with the following commands:

cd opennaas
git checkout develop

Option 3

This is the easiest way to take a look at the code. It will take only a few seconds to download the zip file.

Before clicking on the “Download ZIP” button, you need to select the branch you want to download by expanding the combo and selecting the right version.

Then, you need to extract the file and you can import the project to your chosen Java development tool (see Importing the project section).

Build

Go into the project root and build:

cd opennaas
mvn install

Run

You will find the compiled OpenNaaS distribution target inside:

cd platform/target/opennaas-{version}/opennaas-{version}/bin

If you are running Windows execute:

opennaas.bat

Under Linux or Mac run

opennaas.sh

Now, you know how to download, build and run OpenNaaS. But if you want to start developing follow the next section “Import the project” to navigate throw the files and classes.

Import the project

The development team uses different tools, but we will take as an example the Spring Tool Suite (STS). Follow the next steps to starting developing on OpenNaaS:

  1. Open STS
  2. Select File > Import
  3. Chosse under Maven > Existing Maven Projects
  4. Browse to the directory where you cloned OpenNaaS, select the root directory and click OK.
  5. All the folder will be analyzed and all the maven projects under this folder will be shown. Select all and click Finish.
  6. The import will take a while, so be patient! 😉

Now, you will have all the project imported in your project and you can start adding new resources, features and functionalities. Happy coding!

How could I continue?

You can start with the tutorials creating a new resource and testing it.

If you find any problem, need any assistance or just want to keep posted of all new functionalities added to OpenNaaS, please follow join the developer mailing list.

The OpenNaaS Developer mailing list is for developers to discuss ongoing work, make decisions and vote on technical issues.

  • Subscribe or manage your subscription to the OpenNaaS Developer list
  • Post to the OpenNaaS Developer list
  • View to the OpenNaaS Developer list archive