This repo contains of 4 different apps:
- Main Cockpit App - using ReactJS
- Video-stream App - using Anguar
- Control-center App - using VueJS
- Telemetry-stream App - using ReactJS
For a 'non-development' build, please simply run:
docker-compose build --parallel
docker-compose up
For a 'development' build (live reloading), please simply run:
docker-compose -f docker-compose-reload.yml build --parallel
docker-compose -f docker-compose-reload.yml up
When you modify the package.json
, you will need to re-build the docker files, as the node_modules/
folder is not mounted as volume into the docker image.
Follow these steps to start the Main ReactJS Cockpit App
cd frontends/cockpit
npm run start
For every other app do the following
cd src/*frontend-name*
npm run serve-element
npm run http-server
npm run http-server
will start a http server, which is sourcing the ./dist/*frontend-name*
folder. To ensure the every frontend can run their own http server, every frontend is using another port. Inside the ./dist
folder is the bundled custom element.
npm run serve
will create a custom element and save it to the ./dist
folder.
This way the Main Cockpit App can source the newest version of the bundles directly and no need for coping around the built bundles.