The Datahub Documentation

Introduction / Installation / Usage

Installation

Before installation

The Datahub is a web based application and requires that you have a web server and a database server.

For 'local' or 'online' Linux based servers, the software that is needed to run the Datahub is known as an "AMP" stack, although Microsoft based servers are also known as a stack.

AMP stack stands for

An online web host provides these technologies as part of their service, or you can install them for free on your Linux, MAC, or Windows computer.

System requirements

The Datahub is build with the PHP based web framework Symfony. Records are stored in a separate database managed by the MongoDB database system. What do you exactly need to run the software?

Disk space

A Datahub installation doesn't take a fixed amount of disk space. The core files of the code typically take around 100 MB on your server. You will need extra space for your database, log files and backups though, assuming those reside on the same file system.

Web server

Symfony based applications can be served using different web server products. Here's a list of the most widely used options:

PHP

The Datahub requires PHP 7.0 or a higher version.

You wil also need these extra PHP extensions:

Composer

Symfony based applications are managed using Composer. This is a dependency management tool for PHP. You will need it to download third party packages during installation, and to install updates later on.

MongoDB

The Datahub requires MongoDB 3.2.10 or a higher version.

Step 1: Get the code

The most straightforward way of getting the code is downloading the latest release as a ZIP or TAR ball from Github.

Alternatively, you can download the code from Packagist with Composer:

$ composer require foo/bar

Clone the Git repository from Github, if you plan development.

$ git clone https://github.com/thedatahub/Datahub.git datahub

Step 2: Create a database

You will also need a MongoDB database. Make sure you have a running MongoDB database server. Log in into the Mongo Shell as a database administrator and execute these commands:

> use datahub
> db.createUser(
   {
     user: "datahub",
     pwd: "password",
     roles: [ "readWrite", "dbAdmin" ]
   }
)

Step 3: Install dependencies with Composer

The Datahub application depends on a series of third party code libraries that need to be downloaded. Go into the directory where you downloaded the core files, and execute this command:

$ composer install

This will download all the necessary dependencies and store them in a directory called vendor.

Step 4: Configure your installation

During installation, you will be asked to provide a set of configuration settings. This includes the details of the connection to your MongoDB database.

Your settings will be stored in a file called app/config/parameters.yml.

Step 5: Up and running

Complete the installation by executing these commands which will setup the application and create an application adminstration user.

$ app/console app:setup
$ app/console doctrine:mongodb:fixtures:load --append

PHP comes with its own web server. This is suitable to just test the application without going through the setup of a fully fledged web server. Execute the next command to start the server:

$ app/console server:run

Visit http://127.0.0.1:8000. You should be greeted by the dashboard welcome screen of the Datahub.

Refer to the Symfony setup documentation to complete your installation using a fully featured web server in a production environment.