NMaaS Portal (GUI)
Web-based GUI for browsing, subscription and deployment of applications offered by the NMaaS Platform
Technologies
- Angular 14
- Bootstrap 3
- PrimeNG 14
- Primeflex
- Formio
See package.json
for detailed package list.
Prerequisites
- Install node and npm (min version is node v14, but suggested is v16)
- Install git
- Clone project and run
npm install
in project root directory - (running on server) Build project using
ng build
and deploy using http server of your choice - (running tests) Chrome is required for running tests, however
karma-chrome-launcher
should download Chrome automatically if it is not detected. Run test usingnpm test
ornpm test-headless
. Seepackage.json
for detailed test commands.
Running NMaaS Portal locally
Go tonmaas-portal
directory in terminal or command line
Run command npm start
or ng serve
After successful compilation go to http://localhost:4200
in your browser (do not close terminal or command line)
Note: First run requires entering npm install
command in order to install all of missing dependencies (use --force
or --legacy-peer-deps
due to angular-formio)
Running NMaaS Portal on dedicated machine
In order to run NMaaS Portal on dedicated machine perform the following steps:
- Build the NMaaS Portal by running
gradlew clean build
in the reactor directory.- In order to build for production environment use additional option
--configuration production
- In order to build for production environment use additional option
- The output archive
nmaas-portal-x.x.x.zip
file is created innmaas-portal/build/distributions
directory. - Run the http server in
nmaas-portal/build/app
nohup angular-http-server -p 9009 -s --cors > nmaas-portal.log 2> Error.err < /dev/null &
Lunching tests
Run ./gradlew run testCoverage
in this directory.
Results of executed tests are displayed on screen.
More information about code quality (including code coverage, test status) are available in nmaas-portal/coverage/index.html
Default settings
NMaaS Portal and Platform URLs:
- Portal:
http://<HOSTNAME>:9009
- Platform API:
http://<HOSTNAME>:9001/api
Admin user:
- username:
admin
- password:
admin
Building and uploading NMaaS Portal Docker image
In order to build the NMaaS Portal Docker image first alter the build_and_publish.sh
script with custom REPOSITORY, PACKAGE and TAG values and execute build_and_publish.sh
to automatically build and publish nmaas-portal
image to selected Docker repository.
Issues
As of Angular 14, there is an issue with ivy
and ngcc
, regarding angular-formio
, however everything seems to be working fine.
See Github Issue
The application is maintained through quite some period of time, so there are still some legacy and problematic packages (updated: 2023-08-03:
-
angular-formio
is basically not maintained, there is a dependency clash (it requires old angular version), it must be usually updated with--force
flag duringnpm install
ornpm clean install
. In future new versions may emerge since they are present in git repository, however they are not yet deployed for 2 years. Note:angular-formio
is very much required. -
ngx-pagination
can be replaced withprimeng
counterpart, -
ng-recaptcha
can be updated to the newest version with angular update, -
angular-password-strength-meter
(probably not maintained anymore) can be replaced withprimeng
component and removed together with its dependencies (zxcvbn
,zxcvbn3
), -
bootstrap
- project usesbootstrap v3
however updating bootstrap is not advised, - There are other packages, that are deprecated, e.g.
codelyzer
. However, they should not cause much harm.