Install NodeJS from the Downloads-Page or your package manager.
The following instructions are primarly for Linux. Instructions on MacOS or Windows may require other steps
- Install PostgreSQL either from the Downloads-Page or from your package manager
- Switch to the postgres-user and initialize the database cluster
sudo -iu postgres
initdb -D /var/lib/postgres/data
- Start or enable the PostgreSQL-Service
sudo systemctl start postgresql
- Create a database named
noodle
createdb noodle
- Add a user with the name
noodle
createuser noodle
psql -d noodle -c "CREATE USER noodle WITH PASSWORD 'noodle'; GRANT ALL ON ALL TABLES IN SCHEMA public TO noodle;"
For more information see the the Section Server Setup and Operation in the PostgreSQL-Documentation or the PostgreSQL-Entry in the Arch Linux-Wiki.
- Clone this repository
- Run
npm i
- Set up the database settings in
src/index.ts
andtests/integration/helper.ts
(Only needed if using a different database than describe above) - Run
npm start init
- This will create a administrator with the the username
administrator
and the passwordadministrator
npm start
npm run watch
npm run test
npm run test:e2e
npm run build
The output of the build process will be inside build/
The application can be run by using the package (recommend) or cloning and running/building this repository.
For more information about accquiring the package see the Package Repository
If using the application in production NODE_ENV=development
MUST NOT BE SET.
Not doing so will sign with the JWT with a hardcoded value and produce a huge security risk.
If the packages has been installed globally, use the following command
noodleBackend
If the packages has been installed in a local project, use the application with the following command
npx noodleBackend
This will compile the project and the execute it with node
, to improve performance
npm run start:prod
The API-Documentation can be found in the Wiki For the Module Documentation look here