Spanish Total.js
Français
Documentation Pour les agents IA
Sommaire

Configuration files

The keys of the config files of Admin and Stream, and the start options in index.js.

.md Site web

Cette page n’est pas encore traduite. Tu lis l’original.

Sur cette page

Each app has a config file in its folder. Every line is a key, a colon and a value. Change a value and restart the app.

Admin

KeyWhat it doesExample
nameThe name of the app until you set App name in Settings.IoT Platform
databaseThe connection to the PostgreSQL database.postgresql://user:password@127.0.0.1:5432/iot
urlThe public address of Admin.https://iot.example.com

Keep the other keys of the shipped file as they are.

Stream

KeyWhat it doesExample
nameThe name of the stream.IoT Stream
databaseThe connection to the same PostgreSQL database as Admin.postgresql://user:password@127.0.0.1:5432/iot
urlThe public address of the stream, where devices send their data.https://stream.example.com

Start options in index.js

Both apps start from index.js. The lines that begin with // are switched off. Remove the // to use one:

options.ip = '127.0.0.1';
options.port = 8001;
  • options.ip limits the app to one network address, for example 127.0.0.1 when a web server on the same machine forwards the requests.
  • options.port sets the port. Admin uses 8000 when you start it with npm start.

Start an app with --release for production:

node index.js --release
Fabriqué en Europe