Code Monkey home page Code Monkey logo

gather's Introduction

gather

This application was generated using the NodeJS blueprint of JHipster 7.0.1, you can find documentation and help at https://www.jhipster.tech/documentation-archive/v7.0.1. For any questions you can refer to the stream lead: Angelo Manganiello.

Development

To start your application in the dev profile, simply run:

cd server && npm install
npm run start:dev

Before you can build this project, you must install and configure the following dependencies on your machine:

  1. Node.js: We use Node to run a development web server and build the project. Depending on your system, you can install Node either from source or as a pre-packaged bundle.

After installing Node, you should be able to run the following command to install development tools. You will only need to run this command when dependencies change in package.json.

npm install
cd server && npm install

The npm run command will list all of the scripts available to run for this project.

Using Docker to simplify development (optional)

You can use Docker to improve your JHipster development experience. A number of docker-compose configuration are available in the src/main/docker folder to launch required third party services. You can also fully dockerize your application and all the services that it depends on.

For example, to start a mysql database in a docker container, run:

docker-compose -f src/main/docker/mysql.yml up -d

To stop it and remove the container, run:

docker-compose -f src/main/docker/mysql.yml down

For the entire app run:

docker-compose -f src/main/docker/app.yml up -d

For more information refer to Using Docker and Docker-Compose, this page also contains information on the docker-compose sub-generator (jhipster docker-compose), which is able to generate docker configurations for one or several JHipster applications.

JWT authentication and authorization

Congratulations! You've selected an excellent way to secure your NHipster application. If you're not sure what JSON Web Token (JWT) is, please see What the Heck is JWT?

Your app uses, to get and use the token, the server/src/config/application.yml settings:

  ...
  security:
    authentication:
        jwt:
            # This token must be encoded using Base64 and be at least 256 bits long (you can type `openssl rand -base64 64` on your command line to generate a 512 bits one)
            base64-secret: {yourSecret}
            # Token is valid 24 hours
            token-validity-in-seconds: 86400
            token-validity-in-seconds-for-remember-me: 2592000

You can use the default secret created from the app, or change it. So to get a token, you have to pass a POST request on the api/authenticate url with UserLoginDTO as body. For this you can use swagger ui on /api/v2/api-docs path, or the client login page (if you have generated it).

Using NestJS CLI

You can also use NestJS CLI to generate some custom server code.

For example, the following command:

nest generate module my-module

will generate the file:

create server/src/my-component/my-component.module.ts

Building and running

Running

npm run start:app

Building

npm run build:app

The build folder with all compiled sources will be server/dist.

For more explanation about full stack server/client build refer to server/README.md

Code quality

Sonar is used to analyse code quality. You can start a local Sonar server (accessible on http://localhost:9001) with:

docker-compose -f src/main/docker/sonar.yml up -d

You can run a Sonar analysis with using the sonar-scanner. Then, run a Sonar analysis in the server folder:

npm run sonar:scanner

For more information, refer to the Code quality page.

gather's People

Contributors

aragonbn90 avatar ducanhz135 avatar hieuduongt avatar xuancuongdo avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.