GISCollective developer manual

This section is for those who want to help with the development process, including source code, software releasing, and other administrative work.

Table of contents:
  1. Setting up the dev environment
    1. Git
    2. DLang compiler
    3. Node.js
    4. Mongo
    5. Yarn
    6. Ember.js
  2. Starting the apps
    1. Minimal setup
      1. 1. Start the frontend project:
      2. 2. Start the api server:
    2. The complete setup
      1. 3. Start the HMQ server
      2. 4. Start the DLang tasks
      3. 5. Start the node.js tasks
    3. Other
  3. Next steps

Setting up the dev environment

Before you start contributing to GISCollective, the following tools need to be installed on your system:

Git

GISCollective source code is stored and version in a git repository on GitLab. Visit http://git-scm.com/ and https://about.gitlab.com/ for more details.

DLang compiler

This is the main programming language used for our backend services. For a development environment we prefer to use the DMD compiler but LDC should also work fine. The projects should compile with the latest compiler available.

Node.js

For the frontend and some backend services we use Node.js. The latest LTS version should work fine with our projects.

Mongo

For data persistence, we use the mongo database. A simple MongoDB Community Server instance should work fine for a development setup: https://www.mongodb.com/try/download/community

Yarn

For the node projects we use yarn with workspaces configurations. Check the installation details at this address: https://yarnpkg.com/getting-started/install

Ember.js

For the frontend we ues the ember.js the setup guide can be found in this guide: https://guides.emberjs.com/release/getting-started/quick-start/

Starting the apps

There are multiple components that need to be started in order to have the full setup. You can check the architecture page if you want to better understand the relation between them.

Minimal setup

To start the web frontend and the api, you need to:

1. Start the frontend project:

   > git clone git@gitlab.com:GISCollective/frontend/web-frontend.git

   > cd web-frontend

   > yarn

   > yarn start

2. Start the api server:

   > git clone git@gitlab.com:GISCollective/backend/ogm-server.git

   > cd ogm-server
  • create an app config/configuration.js file based on config/configuration.model.js
  • create a db config/db folder based on config/db.model
  • make sure mongo db is running
   > dub

When you start the api server for the first time, the database will be seeded with some data. You can log in using the admin@example.com email with the admin password.

The complete setup

To have the complete setup you need to run the tasks servers.

3. Start the HMQ server

The HMQ project is the load balancer that we use for the background tasks and it has to be running before the tasks servers are started.

   > git clone git@gitlab.com:GISCollective/backend/hmq.git

   > cd hmq
  • create an app config/configuration.js file based on config/configuration.model.js
  • create a db config/db folder based on config/db.model
  • make sure mongo db is running
   > dub

4. Start the DLang tasks

   > git clone git@gitlab.com:GISCollective/backend/tasks.git

   > cd tasks
  • create an app config/configuration.js file based on config/configuration.model.js
  • create a db config/db folder based on config/db.model
  • make sure mongo db is running
   > dub

5. Start the node.js tasks

   > git clone git@gitlab.com:GISCollective/backend/node.git

   > cd node

   > yarn

   > cd packages/tasks
  • create an app config/configuration.js file based on config/configuration.model.js
  • create a db config/db folder based on config/db.model
  • make sure mongo db is running
   > yarn start

Other

The node repository also contains the batch scripts and the fonts server and for starting those projects you need to follow the same steps like the tasks server.

   > git clone git@gitlab.com:GISCollective/backend/node.git

   > cd node

   > yarn

   > cd packages/<project>
  • create an app config/configuration.js file based on config/configuration.model.js
  • create a db config/db folder based on config/db.model
  • make sure mongo db is running
   > yarn start

Next steps

Once you have the servers running, you can check our Service Desk for the latest issues or questions. Don’t forget to read our Contributing and Code Of Conduct documents.

For a complete overview of GISCollective you can always check the infrastructure document.

If you have any questions you can contact us by email at hello@giscollective.com or using the Service Desk.


Back to top