Skip to content

peace317/rainer-quatsch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is a Next.js project bootstrapped with create-next-app und setup from boilerplate Primereact-Sakai

Build Status Github Tag

Getting Started

Requirements

  • Docker essential for development database
  • Node essential as runtime engine
  • LiveKit local server (optional, if you use the cloud)
  • MongoDB Tools used to execute dumps and imports to the db

VSC Plugin suggestions

  • Prisma for syntax highlighting in prisma files
  • Prettier code formatter
  • Playwright testing in VSC

Additional tooling

Install

To get started, install dependencies with npm:

npm install

Create DB

To setup a Mongodb in Docker run

npm run docker:db-dev

Prisma generate

After that you need to generate the prisma entities.

npx prisma generate

If you have problems with certificates, you may need to set set NODE_TLS_REJECT_UNAUTHORIZED=0 to install prisma client. Other helping commands are npm config set strict-ssl false and npm config set registry "http://registry.npmjs.org/"

Start the server

Then run the server. The server would also start without any other service (e.g. db or websocket server).

npm run dev

Open http://localhost:3000 with your browser to see the result.

Import ruletables

To import ruletables data simply run

npm run db:import

Deployment

To package Next.js for deployment run

npm run build

This will generate the optimal build of the app. In addition to that, it also does code checks with eslint and there should be no errors to continue.

Build docker images

For shipment and final deployment you can run

npm run docker:build

This will build the image for the app and all components.

If you want to only build and update a certain service use

npm run docker:build:app

to build only the specified image.

Deploy

To deploy the the app with an mongodb cluster run

npm run docker:deploy

The db cluster can be accessed with an mongodb express agent http://localhost:8081 (root/prisma)

Testing

For testing simply run

npm run test

Debug local Test run

The easiest way to debug tests is via the VSC Plugin in the testing view or in the testfile itself.

To test the server without running any tests you can run.

npm run dev:test

This start the normal webserver with the test environment configuration.

You can also run the server and execute any test against the server. Playwright won't start another webserver, if there is already one live. This also applies to to socket server.

Now you can start the test run in debug mode.

npm run test:debug

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.

Maintainers

License

MIT © RainerQuatsch

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published