Installation

Introduction

Here are the steps to follow to install the software locally on your machine. The examples are realized on a linux system.

Anis is composed of a monorepo projects thaht contains server, client and services and we will see how to install the stack.

Git Repository

The anis source code is available on a public gitlab repository. Here we will retrieve the anis project by cloning the official git project.

$ git clone git@gitlab.lam.fr:anis/anis-next.git
$ cd anis-next

Makefile

Anis contains a Makefile that helps the developer to install and start the application. Just for information, to list all operations availables just type make in your terminal.

anis_make

Dependencies

Install client dependencies

The client part is written in angular/typescript and requires dependencies to work. To install type this make command:

$ make install_client

The anis-client dependencies packages will be downloaded and placed in a folder named client/node_modules. This may take a few minutes. Just for information, you can find the list of dependencies in the client/package.json file.

Install server dependencies

The server part is written in php and requires dependencies to work. To install type this make command:

$ make install_server

The anis-server dependencies packages will be downloaded and placed in a folder named server/vendor. This may take a few minutes. Just for information, you can find the list of dependencies in the server/composer.json file.

Start application

It is now time to start the anis stack. To do this use the following make command:

$ make start

This command will use the docker-compose.yml file to create and launch the different containers needed for anis. This may also take a few minutes. You can see the status of anis containers by typing the following command:

$ make status

You can also follow the container logs by typing:

$ make logs

Databases

To run anis need at least two databases:

  • One database to store the configuration
  • At least one database containing datasets

In the dev version we provide two ready-made databases. To install them type the following command:

$ make create-db

Anis is ready to use!

Server

  • The server API is available at the following address: http://localhost:8080

anis_server_root

Few examples:

  • To list all datasets available in the default instance: http://localhost:8080/dataset
  • To print all data for the obs_cat dataset with column 1, 2 and 3: http://localhost:8080/search/obs_cat?a=1;2;3
  • To count the number of data available for a request: http://localhost:8080/search/obs_cat?a=count
  • To print only 3 obs_cat data (search by id): http://localhost:8080/search/obs_cat?a=1;2;3&c=1::in::104600094|104600095|104600108

Client

  • The client is available at the following address: http://localhost:4200

Services

  • The services are available at the following address: http://localhost:5000