Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#436 taxi-sample-generator 병합 #437

Merged
merged 78 commits into from
Jan 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
9fb12e8
Initial commit
withSang Feb 23, 2022
ed3f287
done
withSang Feb 23, 2022
76d6a65
Fix big bugs
withSang Feb 23, 2022
ab1be3b
Fix profileImageUrkl
withSang Feb 23, 2022
d3160da
Update README.md
withSang Feb 23, 2022
dff3d46
remove unnecessary URI
withSang Feb 23, 2022
882be6e
Merge from main
withSang Feb 24, 2022
8ccaa08
Add join/abort event and remove hardcoded vars
withSang Feb 25, 2022
a29cad7
Merge pull request #3 from withSang/#2-joinLeaveEvents
withSang Feb 25, 2022
107cd5e
Add npm start script
withSang Feb 26, 2022
7e58c62
Add student ID and email to userSchema
withSang Apr 12, 2022
21fff13
Fix not showing user's rooms
withSang Apr 26, 2022
a109743
Fix: update room participants
withSang May 24, 2022
19cd933
Fix: update outdated schemas
withSang May 24, 2022
eaca78b
Fix: ObjectID to User document
withSang May 24, 2022
1265c15
Add: randomize location
withSang Jul 27, 2022
e8bbbed
Merge pull request #5 from sparcs-kaist/#4-randomize-location
withSang Jul 27, 2022
b5d8f84
Add: Update location model and provide sample data
withSang Aug 3, 2022
14a1492
Add: update environment setting docs
withSang Aug 3, 2022
89da1d3
Add: update chatSchema
withSang Aug 8, 2022
0f4036b
Fix: generating proper profile url
withSang Aug 9, 2022
d588bc6
Add: dump and restore database
withSang Aug 9, 2022
bc131be
Refactor: upgrade mongoose version to 6.5.2
withSang Aug 14, 2022
11b103d
Merge pull request #7 from sparcs-kaist/#6-bump-mongoose-version-up-t…
withSang Aug 14, 2022
aa95712
Fix: fix inconsistency of settlement array
withSang Aug 16, 2022
8d23e3c
Add: separate Socket.io URL environment variable
withSang Aug 19, 2022
50ad05b
Refactor: edit roomSchama and corresponding ft.s
withSang Aug 19, 2022
85e0b0c
Merge pull request #9 from sparcs-kaist/#8-change-roomschema-to-bette…
withSang Aug 25, 2022
98efa66
Fix: replace readFileSync
withSang Sep 3, 2022
36aff21
Merge pull request #11 from sparcs-kaist/#10-bug-replace-readfilesync…
withSang Sep 3, 2022
090baf8
Remove: remove isOver attribute from roomSchema
withSang Oct 22, 2022
4ee98ec
Fix: restore room.isDone
withSang Oct 22, 2022
4bc0365
Add: Separate user.room into ongoingRoom & doneRoom
withSang Oct 22, 2022
6ecc4ce
Merge pull request #14 from sparcs-kaist/#13-divide-room-attribute-of…
withSang Nov 3, 2022
b66d0b4
Add: location
imYourChoi Nov 8, 2022
9397c73
Remove: white space
imYourChoi Nov 8, 2022
045362c
Merge pull request #16 from sparcs-kaist/#15-add-location
14KGun Nov 9, 2022
cd9a1e3
Fix: location name
imYourChoi Nov 9, 2022
54f14b3
Merge pull request #18 from sparcs-kaist/#17-장소-이름-변경
imYourChoi Nov 9, 2022
0fbd761
Add: location
imYourChoi Nov 11, 2022
a993bb7
Merge pull request #20 from sparcs-kaist/#19-add-location
imYourChoi Nov 11, 2022
ffaa0c7
Refactor: change parameters to default value
chlehdwon Nov 16, 2022
02fea92
Refactor: set parameters to default values if undefined
chlehdwon Nov 20, 2022
d6656a0
Merge pull request #22 from sparcs-kaist/#21-env-구조-변경
chlehdwon Nov 22, 2022
a47ef01
Fix: fix DB not initialized
withSang Nov 22, 2022
cff28f3
Refractor: remove unnecessary variables
withSang Nov 22, 2022
374f7b1
Merge pull request #24 from sparcs-kaist/#23-unable-to-drop-database
chlehdwon Nov 22, 2022
32d350f
Add: dockerfile
14KGun Dec 5, 2022
ec55664
Refactor: dockerfile
14KGun Dec 5, 2022
0807147
Refactor: Dockerfile
14KGun Dec 5, 2022
9c5cbec
Refactor: Dockerfile
14KGun Dec 20, 2022
ddecbb7
Refactor: Dockerfile
14KGun Dec 20, 2022
b182d26
Refactor: Dockerfile
14KGun Dec 21, 2022
8400513
Refactor: .dockerignore
14KGun Dec 21, 2022
abf4164
Add: push_image_ecr.yml
14KGun Dec 22, 2022
a8bdc64
Merge pull request #26 from sparcs-kaist/#25-dockerfile
14KGun Dec 26, 2022
7086f47
fix: update package manager to pnpm
cokia Aug 9, 2023
125ec3b
fix: pnpm import
cokia Aug 9, 2023
bd4329c
Merge pull request #29 from sparcs-kaist/#28-PNPM-MIGRATE
cokia Aug 9, 2023
f1058ef
Remove: taxi-sample-generator submodule
kmc7468 Nov 21, 2023
70ca336
Add: merge taxi-sample-generator into taxi-back
kmc7468 Nov 21, 2023
3acf72f
Remove: duplicated code from sampleGenerator
kmc7468 Nov 21, 2023
5f8e6c2
Refactor: package.json
kmc7468 Nov 21, 2023
8caf7c8
Fix: CI error
kmc7468 Nov 21, 2023
33c5b7a
Fix: test error
kmc7468 Nov 21, 2023
c9f9c77
Remove: .github directory in sampleGenerator
kmc7468 Nov 23, 2023
2f6d44c
Add: longitude and latitude of sample data
kmc7468 Nov 23, 2023
81d403e
Remove: Dockerfile
kmc7468 Jan 6, 2024
ca2b083
Refactor: merge .env file of sampleGenerator into .env.test file
kmc7468 Jan 6, 2024
01e3ac4
Remove: unnecessary async call
kmc7468 Jan 6, 2024
4143c33
Merge branch 'dev' into #436-merge-sample-generator
kmc7468 Jan 6, 2024
2179ae3
Fix: tools/dump.js and restore.js
kmc7468 Jan 6, 2024
7face69
Fix: restoreDB not working
kmc7468 Jan 6, 2024
0a8e4cb
Docs: remove the hyperlink into taxiSampleGenerator in README.md
kmc7468 Jan 9, 2024
919bfd7
Remove: .env.example in taxiSampleGenerator
kmc7468 Jan 21, 2024
e03a118
Remove: .gitmodules
kmc7468 Jan 21, 2024
16d6265
Fix: pnpm install error
kmc7468 Jan 21, 2024
a17c3ef
Merge branch 'dev' into #436-merge-sample-generator
kmc7468 Jan 23, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,10 @@ CORS_WHITELIST=[CORS 정책에서 허용하는 도메인의 목록(e.g. ["http:/
GOOGLE_APPLICATION_CREDENTIALS=[GOOGLE_APPLICATION_CREDENTIALS JSON]
TEST_ACCOUNTS=[스팍스SSO로 로그인시 무조건 테스트로 로그인이 가능한 허용 아이디 목록]
SLACK_REPORT_WEBHOOK_URL=[Slack 웹훅 URL들이 담긴 JSON]

# optional environment variables for taxiSampleGenerator
SAMPLE_NUM_OF_ROOMS=[방의 개수]
SAMPLE_NUM_OF_CHATS=[각 방의 채팅 개수]
SAMPLE_MAXIMUM_INTERVAL_BETWEEN_CHATS=[채팅 간 최대 시간 간격(단위: 초, 실수도 가능)]
SAMPLE_OCCURENCE_OF_JOIN=[새로운 채팅이 입장 메세지일 확률(0 ~ 1 사이의 값)]
SAMPLE_OCCURENCE_OF_ABORT=[새로운 채팅이 퇴장 메세지일 확률(0 ~ 1 사이의 값)]
14 changes: 0 additions & 14 deletions .github/workflows/test_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,6 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
- id: submodule-local
name: Save local version of submodule
run: echo "ver=`cd sampleGenerator && git log --pretty="%h" -1 && cd ..`" >> $GITHUB_OUTPUT
- id: submodule-origin
name: Save origin version of submodule
run: echo "ver=`cd sampleGenerator && git log origin --pretty="%h" -1 && cd ..`" >> $GITHUB_OUTPUT
- name: Check submodule version
if: ${{ steps.submodule-local.outputs.ver != steps.submodule-origin.outputs.ver }}
uses: actions/github-script@v3
with:
script: |
core.setFailed('Please update submodule to the latest version by using \"git submodule update --remote\"')
- name: Install sampleGenerator dependencies from package-lock.json
run: cd sampleGenerator && pnpm i --force --frozen-lockfile && cd ..
- name: Install taxi-back dependencies from package-lock.json
run: pnpm i --force --frozen-lockfile
- name: Run unit tests
Expand Down
4 changes: 0 additions & 4 deletions .gitmodules

This file was deleted.

1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,3 @@ See [contributors](https://github.com/sparcs-kaist/taxi-front/graphs/contributor
- app : https://github.com/sparcs-kaist/taxi-app
- docker : https://github.com/sparcs-kaist/taxi-docker
- figma : https://www.figma.com/file/li34hP1oStJAzLNjcG5KjN/SPARCS-Taxi?node-id=0%3A1
- taxiSampleGenerator : https://github.com/sparcs-kaist/taxiSampleGenerator
9 changes: 7 additions & 2 deletions app.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
// 모듈 require
const express = require("express");
const http = require("http");
const { nodeEnv, port: httpPort, eventConfig } = require("./loadenv");
const {
nodeEnv,
port: httpPort,
eventConfig,
mongo: mongoUrl,
} = require("./loadenv");
const logger = require("./src/modules/logger");
const { connectDatabase } = require("./src/modules/stores/mongo");
const { startSocketServer } = require("./src/modules/socket");
Expand All @@ -13,7 +18,7 @@ require("./src/modules/fcm").initializeApp();
const app = express();

// 데이터베이스 연결
connectDatabase();
connectDatabase(mongoUrl);

// [Middleware] request body 파싱
app.use(express.urlencoded({ extended: false }));
Expand Down
2 changes: 1 addition & 1 deletion loadenv.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,5 @@ module.exports = {
slackWebhookUrl: {
report: process.env.SLACK_REPORT_WEBHOOK_URL || "", // optional
},
eventConfig: process.env.EVENT_CONFIG && JSON.parse(process.env.EVENT_CONFIG),
eventConfig: process.env.EVENT_CONFIG && JSON.parse(process.env.EVENT_CONFIG), // optional
};
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"serve": "cross-env TZ='Asia/Seoul' NODE_ENV=production node app.js",
"runscript": "cross-env TZ='Asia/Seoul' NODE_ENV=production node",
"lint": "npx eslint --fix .",
"sample": "cd sampleGenerator && npm start && cd .."
"sample": "cd src/sampleGenerator && npm start && cd .."
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이런식으로 samplegenerator 스크립트 실행시켜도 좋을 것 같네요

https://github.com/sparcs-kaist/taxi-front/blob/0a759afab95386cc5d9663a0e7cd77150f516ab0/package.json#L7

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pnpm -F taxisamplegenerator 로 시도해 봤는데 안되네요! ㅜㅜ

},
"engines": {
"node": ">=18.0.0",
Expand Down Expand Up @@ -60,7 +60,7 @@
"eslint": "^8.22.0",
"eslint-plugin-mocha": "^10.1.0",
"mocha": "^10.2.0",
"mongodb": "^6.2.0",
"mongodb": "^4.1.0",
"nodemon": "^3.0.1",
"supertest": "^6.2.4"
}
Expand Down
Loading
Loading