opt-cc/README.md

79 lines
2.4 KiB
Markdown

# Operation Pandora Trigger Commandcenter
A [MEAN Application](http://mean.io/) created for [operation-pandora.com](https://www.operation-pandora.com) Arma3 Community
## Installation
All steps described here are working with a Debian based Linux system
### Setup required 3rd Party Software
#### Setup for Development
Run the installation script located in the docs folder:
```text
./docs/opt-cc-environment/3rd-party-install.sh
```
It installs NPM, Node and MongoDB on latest versions.
In addition, it sets up the mongo deamon to start up automatically with the system.
#### Setup for Production
**NOTE:** It his highly recommended **not** to run the following steps as _root_ user!
For production setup run the script, described in _Setup for development_, adding the parameter `prod`
```text
./docs/opt-cc-environment/3rd-party-install.sh prod
```
This adds the [`pm2` process manager](http://pm2.keymetrics.io/) to be installed and start the _opt-cc_ server as `pm2` process.
Run the `sudo` command printed as last output to configure the `pm2` process for automatic start on the system.
## Development
### Run and Modify Application
**NOTE:** Do not use the execution described here in any production environment! It will make the running application highly vulnerable.
Before triggering the environment execution run
```text
npm install
```
inside the main folder, to process all needed npm package installations for the program execution.
To compile the Angular code and afterwards start the Express server with `nodemon` for development purpose run
```text
npm run dev
```
Any changes on `api` code will trigger an automatic restart of the Express server.
Changes on `static` code can be submitted with
```text
npm run deploy-static
```
The page must be reloaded after this build step is finished, in order to make changes visible.
## Run Tests
_TODO_
## License Information
### Express API (`/api`)
published under [CC BY-SA 4.0 License](https://creativecommons.org/licenses/by-sa/4.0/legalcode.txt) \
Main concept for API Server, pagination and MongoDB usage by [Prof. Dr.-Ing. Johannes Konert](https://prof.beuth-hochschule.de/konert/) \
All endpoints, signature image builder and Arma3 RPT-Log parsing by [Florian Hartwich](https://de.linkedin.com/in/florian-hartwich-b67b02125)
### Angular 5 Frontend (`/static`)
published under [MIT License](https://opensource.org/licenses/MIT)