Welcome, this project is part of our Course Conclusion Work (TCC) of the technical course of Development of systems of the SENAI Suiço-Brasileira Paulo Ernesto Tolle School.
- About the project
- Resources used in this project
- How to start the application
- Documentation
- Tests
- How to contribute to with the project
- Developers
- License
This application was requested by the coordinator of the Senai Suiço-Brasileira school, in order to control the prints made by the different sectors of the school (teachers, employees, etc.), thus being able to better manage costs and waste.
|
|
|
|
|
|
- Express 4.17.1 - It is a framework for Node.js that provides minimal resources for building web servers.
- Nodemon 2.0.13 - To restart the server whenever there is a change.
- Jsonwebtoken 8.5.1 - To protect private routes.
- Bcrypt 5.0.1 - To Encrypt user passwords before saving to bank.
- Crypto 1.0.1 - Used to create a random Token that will be transformed into a string.
- Cors 2.8.5 - It is a mechanism used by browsers to share resources between different sources
- Multer 1.4.2 - It is a node.js middleware to handle multipart, which is mainly used to upload files.
- Nodemailer 6.6.3 - Used to send e-mails.
- MariaDB 2.5.4 - It's the database we use.
- Dotenv 10.0.0 - Used to place environment variables (sensitive data).
-
Before you start, you will need to have installed on your machine the following tools: Git, Node.js.
-
Besides, it's good to have an editor to work with the code as: VSCode.
-
Clone or download this repository to your machine.
-
Install the project dependencies, with the
npm install
oryarn install
command if you have yarn installed -
The
.env.sample
file is used to configure all the environment variables you need, such as information about your database. Change all the information so that the application works properly.
# DataBase
DB_HOST=
DB_PORT=
DB_USER=
DB_PASSWORD=
DB_DATABASE=
DB_DIALECT=
# Mailer
# example: hotmail
MAILER_SERVICE=
MAILER_USER=
MAILER_PASS=
# Email that requests / reprography evaluations will be sent
MAILER_COMPANY_EMAIL=
# Front-end Host and Port that will be sent in password recovery email
# example: http://localhost:3002
MAILER_HOST_PORT=
# JWT
JWT_SECRET_KEY=
HEADER_KEY=
SALT_ROUNDS=
# First Account in application
ADMIN_EMAIL=
ADMIN_PASS=
- Remember to rename this file to
.env
to be able to run the application
Important: Before you start the application, first create the database that you entered in DB_DATABASE in the configuration file of the environment variables.
Run the command below to start Nodejs and connect to the database:
# To start normally -> will run the "start" script of package.json.
$ npm run start
# To start in development mode (requires nodemon) -> will run the package.json "dev" script.
$ npm run dev
If you prefer Yarn:
# To start normally -> will run the "start" script of package.json.
$ yarn start
# To start in development mode (requires nodemon) -> will run the package.json "dev" script.
$ yarn dev
⚡ Wait for the API to run and the API will be running at the URL: http://localhost:3002
And so you will have your application running locally.
- Do a fork of the project.
- Create a new branch with your changes:
git checkout -b my-feature
- Save the changes and create a commit message telling you what you've done:
git commit -m "feature: My new feature"
- Submit your changes:
git push origin my-feature
If you have any questions check out this guide on how to contribute to GitHub
Lucca ❄️TechLead❄️ |
Patrick ❄️⛄❄️ |
Daniel Santos ❄️⛄❄️ |
Oseias Farias Jesus ❄️⛄❄️ |
João Otávio ❄️⛄❄️ |
Tiago Soares ❄️⛄❄️ |
📝 License
This project is under the MIT license.