HyeonJun Jeon

[Add] ConnectionLimit option

...@@ -3,8 +3,6 @@ ...@@ -3,8 +3,6 @@
3 [![puppeteer](https://img.shields.io/badge/puppeteer-40B5A4?style=flat-square&logo=puppeteer&logoColor=white)](https://developers.google.com/web/tools/puppeteer) 3 [![puppeteer](https://img.shields.io/badge/puppeteer-40B5A4?style=flat-square&logo=puppeteer&logoColor=white)](https://developers.google.com/web/tools/puppeteer)
4 [![React](https://img.shields.io/badge/React-61DAFB?style=flat-square&logo=React&logoColor=white)](https://developers.google.com/web/tools/puppeteer) 4 [![React](https://img.shields.io/badge/React-61DAFB?style=flat-square&logo=React&logoColor=white)](https://developers.google.com/web/tools/puppeteer)
5 5
6 -
7 -
8 # E-Campus 연동 확장 캘린더 6 # E-Campus 연동 확장 캘린더
9 7
10 [E-Campus 연동 확장 캘린더](http://3.34.173.161:3001/) 8 [E-Campus 연동 확장 캘린더](http://3.34.173.161:3001/)
...@@ -32,6 +30,7 @@ ...@@ -32,6 +30,7 @@
32 ## Getting Started (Installation) 30 ## Getting Started (Installation)
33 31
34 ### Set up 32 ### Set up
33 +
35 ```sh 34 ```sh
36 git clone http://khuhub.khu.ac.kr/2021105636/Extended-Calendar.git 35 git clone http://khuhub.khu.ac.kr/2021105636/Extended-Calendar.git
37 npm install 36 npm install
...@@ -40,12 +39,14 @@ npm install -g pm2 ...@@ -40,12 +39,14 @@ npm install -g pm2
40 ``` 39 ```
41 40
42 Make `.env` in root directory. 41 Make `.env` in root directory.
42 +
43 ```sh 43 ```sh
44 # MySQL 44 # MySQL
45 DB_HOST= 45 DB_HOST=
46 DB_USER= 46 DB_USER=
47 DB_PASSWORD= 47 DB_PASSWORD=
48 DB_DATABASE= 48 DB_DATABASE=
49 +DB_CONNECTION_LIMIT=
49 50
50 # Express 51 # Express
51 SERVER_IP= 52 SERVER_IP=
...@@ -58,38 +59,47 @@ REACT_APP_SERVER_IP= # generally all the same ...@@ -58,38 +59,47 @@ REACT_APP_SERVER_IP= # generally all the same
58 Import `schema.sql` in your DB. 59 Import `schema.sql` in your DB.
59 60
60 ### Run to debug 61 ### Run to debug
62 +
61 Terminal 1 ( Server ) 63 Terminal 1 ( Server )
64 +
62 ```sh 65 ```sh
63 npm run server 66 npm run server
64 ``` 67 ```
68 +
65 Terminal 2 ( React ) 69 Terminal 2 ( React )
70 +
66 ```sh 71 ```sh
67 npm start 72 npm start
68 ``` 73 ```
69 74
70 port : 3000 75 port : 3000
71 <br> 76 <br>
77 +
72 ### Run to deploy 78 ### Run to deploy
79 +
73 ```sh 80 ```sh
74 npm run build 81 npm run build
75 npm run pm2 82 npm run pm2
76 ``` 83 ```
84 +
77 port : 3001 85 port : 3001
78 <br> 86 <br>
79 <br> 87 <br>
80 88
81 ## Usage 89 ## Usage
90 +
82 1. Enter your E-Campus ID and PW. 91 1. Enter your E-Campus ID and PW.
83 -<img src="/uploads/074a79ad560922af309e39b3186cbe2d/image.png" width="300" height="100"> 92 + <img src="/uploads/074a79ad560922af309e39b3186cbe2d/image.png" width="300" height="100">
84 2. If the ID and password entered are correct, your ecampus information-based calendar will be created. 93 2. If the ID and password entered are correct, your ecampus information-based calendar will be created.
85 3. Make sure that the courses you are taking are listed on the left and that your ecampus schedule reflects well. 94 3. Make sure that the courses you are taking are listed on the left and that your ecampus schedule reflects well.
86 4. You can add a new schedule by clicking on the empty part of the calendar. 95 4. You can add a new schedule by clicking on the empty part of the calendar.
87 5. You can view the schedule by day, week, and month. 96 5. You can view the schedule by day, week, and month.
88 6. If you have finished checking the schedule, press the '로그아웃' button in the upper right corner. 97 6. If you have finished checking the schedule, press the '로그아웃' button in the upper right corner.
89 98
90 -
91 ## Contributing 99 ## Contributing
100 +
92 If you would like to add new features to this calendar, please follow these steps: 101 If you would like to add new features to this calendar, please follow these steps:
102 +
93 1. Fork the Project 103 1. Fork the Project
94 2. Create your Feature Branch 104 2. Create your Feature Branch
95 3. Commit your Changes 105 3. Commit your Changes
......
...@@ -7,6 +7,7 @@ const poolOptions = { ...@@ -7,6 +7,7 @@ const poolOptions = {
7 user: process.env.DB_USER, 7 user: process.env.DB_USER,
8 password: process.env.DB_PASSWORD, 8 password: process.env.DB_PASSWORD,
9 database: process.env.DB_DATABASE, 9 database: process.env.DB_DATABASE,
10 + connectionLimit: process.env.DB_CONNECTION_LIMIT,
10 }; 11 };
11 const pool = mysql2.createPool(poolOptions); 12 const pool = mysql2.createPool(poolOptions);
12 13
......