wiki:programmersguide/configuringterrama2

Version 6 (modified by jano.simas, 9 years ago) (diff)

--

Configuring TerraMA2

To execute the TerraMA2 you'll need a few things.

Postgres/PostGIS user

By default the installation of the Postgres/PostGIS creates a user postgres with no password. You may use this user but a password must be set.

To create a password to the postgres user:

sudo -u postgres psql
ALTER USER postgres WITH PASSWORD '<password>';
\q

If you prefer to create a new user, you'll be prompted for a password :

sudo -u postgres psql
CREATE USER <user> WITH PASSWORD '<password>';
\q

Check the configuration files

A default configuration file is created when TerraMA2 is installed, but you may need to update some information.

In a default installation you'll find two configuration files, the webapp configuration can be found in the path:

/opt/terrama2/4.x.x/webapp/config/config.terrama2

In this file you must configure:

  • The Postgres/PostGIS user and password
  • The webapp port, this is where the user will connect

You may have more then one configuration for different instances of the TerraMA2 ToDo?

The webmonitor configuration file can be found in:

/opt/terrama2/4.x.x/webmonitor/config/config.terrama2

In this file you must configure:

  • The webmonitor port, this is where the user will connect
  • The webapp ip and port, this is the port that was configured in the webapp config file.

Restart

If the webapp and webmonitor are already running when you change the configuration you'll need to restart your services. Just run the command:

sudo pm2 restart webapp webmonitor

Screen

To execute the TerraMA2 you'll need to have in the target machine to software screen installed:

sudo apt-get install screen