FOM projects (proposals for logging, essentially) are submitted to FOM and made available for public review and comment. The submitting organization then needs to address the comments before submitting the project to the ministry.
Technology Stack: Angular, Node.js with Nest/TypeORM framework, PostgresSQL with PostGIS running in OCP v4
The officially supported version of node is v14 LTS and npm is v6.
This is a repo that includes the API backend and the two Angular front-ends with a shared 'libs'.
See ministry Confluence site: https://apps.nrs.gov.bc.ca/int/confluence/pages/viewpage.action?pageId=83560736
Once set up, the stack can be access using the following paths on localhost:
- Postgres: localhost:5432
- API: localhost:3333/api
- Admin frontend: localhost:4200/admin
- Public frontend: localhost:4300/public
- Install docker and docker-compose
- Run
docker-compose up
Individual components can be started separately or daemonized. E.g. database in the background (daemonized), the api in the foreground:
docker-compose up -d db
docker-compose up api
- Install dbeaver or pgadmin
- Ensure database is running (docker-compose up -d db && cd api && npm run typeorm:migrate)
- Create PostGRES connection to local database using connection information as defined in docker-compose.yml
This drops and recreates the database and runs all migrations including test ones. (Although migrations are also run when starting the API component, test migrations only run at startup if environment variable DB_TESTDATA = true)
- npm run db:recreate
To explicitly delete database:
- docker-compose down
- docker volume rm nr-fom-api_ms-postgres-data
- API Backend - See setup at API Backend Readme.
- See Client Library Generation at API Backend Readme.
Due to the minimal automated tests, the following should be done after major dependency changes:
- (API Backend): npm run build:api
- (API Backend): npm run test-unit
- (Public Frontend): npm run start:public
- (Admin Frontend): npm run start:admin (ideally with security and object storage enabled)
- (API Backend): npm run start:api
- Test both front-ends.
If you would like to contribute, please see our CONTRIBUTING guidelines.
Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.
- See LICENSE