Step 3 Build and run application¶
For all further commands, run command prompt as Administrator.
Go to the application folder
cd c:\workspace\framework``and set the environment variable ``NODE_PATH equal to the path to the application. For Windows: command
set NODE_PATH=c:\workspace\framework, for Linux:
Building the application provides installing all the libraries, importing the data into the database, and preparing the application to run.
At the first launch, you need to run
npm installcommand to install key dependencies, including the
gulptask runner locally. Make sure that the
4.0. This command will install all the libraries from the ``dependencies``property of ``package.json``file of the core.
After that, and in all the next times, run the command
gulp assembleto build the application.
NB: Make sure that the environment variable
NODE_PATHis set, the
MongoDBdatabase is running, the
Gulpis globally and locally installed and its version is``4.0``.
Before launching the application, add a basic user for logging in. Open``Mongo Compass`` app and find the
ion-user``table in the database. Delete all the records you see there. Then go back to the console and execute the commands below. Add ``adminuser with
123password using command
node bin/adduser.js --name admin --pwd 123. Add administrator rights to the user using command
node bin/acl.js --u admin@local --role admin --p full.
Launch application using scripts¶
bin folder contains the scripts to run applications based on the IONDV.Framework, such as:
- import.js and import-data.js
NB. Запускаются локально из папки framework, шаблоны команд указаны в разделах с описанием назначения скрипта.
More details about application launch scripts
After finishing the build you can launch the app. Make sure that the environment variable
NODE_PATH is set. If skipping this step, the system will show the missing components error.
The system is launched by the command
npm start, alternative launch is
After launching the system, open the browser with
http://localhost:8888``adress and log in to the application, where ``8888 is a port specified in the
server.ports parameter in the launch configuration.