Step 2 Install core, modules and application¶
Clone application and its components¶
NB: paths should not contain Russian letters and spaces. We recommend that you place your application in c:\workspace
.
Let’s examine the creating a project with modules using the develop-and-test
application as an example.
- Find the application on github. Search for
develop-and-test
and click it. - Go to the file repository on the version branch.
- Open
package.json
file to check the dependencies.
"engines": {
"ion": "3.0.0"
},
"ionModulesDependencies": {
"registry": "3.0.0",
"geomap": "1.5.0",
"portal": "1.4.0",
"report": "2.0.0",
"ionadmin": "2.0.0",
"dashboard": "1.1.0",
"soap": "1.1.2"
},
"ionMetaDependencies": {
"viewlib": "0.9.1"
}
engines": "ion": 3.0.0
- version of the core3.0.0
.ionModulesDependencies
- list of modules and their versions.ionMetaDependencies
- list of other metadata required for the project; in this case the ``viewlib``exception is a view library.
NB: to switch to tag version number, see versions in package.json
file.
Getting repository of the core¶
The core is located in the repository framework. The field containing the path to the repository is at the main page.
- Run the command prompt as Administrator.
- Copy the repository path, go to the workspace folder using command
cd c:\workspace
and rungit clone https://github.com/iondv/framework
. The command will create theframework
folder and clone the repository into it.
Getting Modules¶
- Go to the modules flofer using command
cd framework\modules
. - For each module from the
package.json
list in theionModulesDependencies
property find the module repository among the group of modules``https://github.com/iondv/ION-MODULES``. - Clone all the modules from the
ionModulesDependencies
list using commandgit clone https://github.com/iondv/registry
. - Go to the folder of the installed module, switch to thetag version number
git checkout tags/v1.27.1
. For example1.27.1
is a number ofregistry
module version. - Repeat for each module.
Getting Application¶
- Go to the application folder. If you are in the modules folder, run
cd ..\applications
. - Next, go back to the
develop-and-test
repository page, copy the path and clone it using commandgit clone https://github.com/iondv/develop-and-test
. - Go to the folder of the installed application, switch to the tag version number
git checkout tags/v1.17.0
. - The dependencies installation in
ionMetaDependencies
is carried out in theapplications
folder. For installation make sure you’re in the applications folder. Clone the applications from the list in theionMetaDependencies
parameter. For``viewlib`` application clone using command``git clone https://github.com/iondv/viewlib``. - Go to the folder of the installed application, switch to the tag version number
git checkout tags/v0.9.1
. Repeat for each application. - The application is compiled.
NB: we recommend creating a project for it in an IDE, for example Visual Studio Code, and creating the configuration file in it.
Config file¶
Config file is for setting the main parameters of the app environment and configuring the additional start parameters.
- Create
setup
config file withini
extension inconfig
folder. - Open the file in the editor and paste the contents.
auth.denyTop=false
auth.registration=false
auth.exclude[]=/files/**
auth.exclude[]=/images/**
db.uri=mongodb://127.0.0.1:27017/iondv-dnt-db
server.ports[]=8888
module.default=registry
fs.storageRoot=./files
fs.urlBase=/files
The main parameter is db.uri=mongodb://127.0.0.1:27017/db
. It indicates the name of the database we’ll use for the application. The database will be created authomatically.