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

[BE] 브랜치 병합 #79

Merged
merged 219 commits into from
Nov 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
219 commits
Select commit Hold shift + click to select a range
88b97c1
Merge pull request #23 from boostcampwm-2024/back/main
jinddings Nov 5, 2024
5d5318b
➕ add : express 모듈의 Request 타입 선언 재정의(#7)
jinddings Nov 7, 2024
0a276f9
⚙️ chore : typeOrmModule이 모든 entity 포함하도록 변경(#7)
jinddings Nov 7, 2024
4357a54
✨ feat : refresh Token 구현(#7)
jinddings Nov 7, 2024
a9c95d7
✨ feat : Token Refresh 요청 API 구현(#7)
jinddings Nov 7, 2024
91607bd
➕ add : kakao strategy 추가(#4)
jinddings Nov 7, 2024
0f58a72
Merge branch 'back/main' into feature/api/login-#7
jinddings Nov 7, 2024
d5e7764
Merge pull request #35 from boostcampwm-2024/back/main
jinddings Nov 7, 2024
99362cd
♻️ refactor: getFullUrl, getHeader 적용
sieunie Nov 8, 2024
6549725
♻️ refactor: stock index 관련 소켓 이벤트, response 형식 변경
sieunie Nov 8, 2024
d65c70b
🔧 fix: service 에러를 http 에러로 변경
sieunie Nov 8, 2024
462c8a1
🔧 fix: getAccessToken 로직 오류 수정
sieunie Nov 8, 2024
f210aa0
➕ add: 차트 response에 전일 대비 값 추가
sieunie Nov 9, 2024
19fccb7
♻️ refactor: 백엔드 파일명 통일
sieunie Nov 11, 2024
5920449
Merge pull request #47 from boostcampwm-2024/feature/api/stockindex-#6
sieunie Nov 11, 2024
123b608
Merge pull request #46 from boostcampwm-2024/dev
jinddings Nov 11, 2024
b508aee
Merge pull request #58 from boostcampwm-2024/back/main
sieunie Nov 11, 2024
1fe2082
🔧 fix : merge confict 수정
jinddings Nov 11, 2024
b872066
♻️ refactor: lint 에 위배되는 코드 수정
jinddings Nov 11, 2024
afc77fb
✨ feat: 주식현재가 API 요청에 대한 응답값 interface 구현
uuuo3o Nov 11, 2024
1a48a8b
✨ feat: 주식현재가 API 요청에 필요한 쿼리 파라미터 DTO 구현
uuuo3o Nov 11, 2024
3053dd2
✨ feat: 주식현재가 API 요청 코드 구현
uuuo3o Nov 11, 2024
05200cf
🔧 fix: output에 대한 정보가 잘못된 부분 수정
uuuo3o Nov 11, 2024
35b332d
✨ feat: 주식현재가 API로부터 받아온 데이터 정제 및 반환하는 코드 구현
uuuo3o Nov 11, 2024
08bb77d
✨ feat: 특정 주식의 주식현재가 시세 데이터를 반환하는 controller 구현
uuuo3o Nov 11, 2024
1c7c1e9
⚙️ chore : alpha서버 배포와 production을 위한 CI/CD분리
jinddings Nov 11, 2024
cc7592a
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
jinddings Nov 11, 2024
697eb50
✨ feat: jwt authGuard 추가
sieunie Nov 11, 2024
e1d5582
✨ feat: 주식 매수 API 구현 #49
sieunie Nov 11, 2024
403e99b
Merge branch 'dev' of https://github.com/boostcampwm-2024/web16-JuGa …
jinddings Nov 11, 2024
89f4aa9
Merge pull request #68 from boostcampwm-2024/back/main
jinddings Nov 11, 2024
5421860
✨ feat: 주식 매도 API 구현 #50
sieunie Nov 11, 2024
bbcb40e
⚙️ chore : FE lint 오류 수정
jinddings Nov 11, 2024
59ecabb
✨ feat: 특정 주식의 주식현재가 시세 데이터 반환 DTO 구현
uuuo3o Nov 11, 2024
c1ff7ee
⚙️ chore: 린트 규칙 추가
uuuo3o Nov 11, 2024
50b9170
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
jinddings Nov 11, 2024
2298435
✨ feat: 주식 매도/매수 취소 API 구현 #51 #52
sieunie Nov 11, 2024
b760a20
🔧 fix: 국내주식기간별시세 API에 사용할 interface로 수정
uuuo3o Nov 11, 2024
7f20998
🔧 fix : refreshToken, accessToken response 방식 수정
jinddings Nov 11, 2024
e1dda3f
🔧 fix : jwt secret .env에서 읽도록 수정, refresh API 응답 방식 수정
jinddings Nov 11, 2024
3e0df74
Merge pull request #43 from boostcampwm-2024/feature/api/login-#7
jinddings Nov 11, 2024
1c163ea
✨ feat: 국내주식기간별시세 API에 사용할 DTO로 수정 및 추가
uuuo3o Nov 11, 2024
3d548b9
Merge branch 'alpha' into back/main
jinddings Nov 11, 2024
e8969c7
🔧 fix : lint 오류 수정
jinddings Nov 11, 2024
ddbbd79
🔧 fix : lint 오류 수정
jinddings Nov 11, 2024
80dd583
🚚 rename: 파일명을 명확하게 변경
uuuo3o Nov 11, 2024
14aa4eb
⚙️ chore : deploy alpha 디버그 코드 추가
jinddings Nov 11, 2024
3f09927
⚙️ chore : npm install 코드 수정
jinddings Nov 11, 2024
12abb63
✨ feat: 국내주식기간별시세 API 요구사항에 맞춰 service, controller 수정
uuuo3o Nov 11, 2024
5061b7f
⚙️ chore : action 버전 수정
jinddings Nov 11, 2024
2cf4769
⚙️ chore : audit 무시
jinddings Nov 11, 2024
053c7a9
⚙️ chore : continue on error 추가
jinddings Nov 11, 2024
b933cb7
⚙️ chore : npm run test BE 디렉토리에서만 실행
jinddings Nov 11, 2024
351c474
💡 comment: 주석 추가 및 불필요한 코드 삭제
uuuo3o Nov 11, 2024
ea3d296
Merge branch 'back/main' into feature/api/stockDetail-#54
uuuo3o Nov 11, 2024
c3ccb20
⚙️ chore : key secret 변경
jinddings Nov 11, 2024
8c5dc07
Merge branch 'back/main' into feature/api/stockbuy-#49
sieunie Nov 11, 2024
cce5466
merge conflict resolve app.module.ts
sieunie Nov 11, 2024
0cf7bca
⚙️ chore : 동시에 두 가지 job 이 실행되지 않도록 변경
jinddings Nov 11, 2024
8ecc422
♻️ refactor: remove unused import
sieunie Nov 11, 2024
40a90e2
Merge branch 'back/main' into feature/api/stocksell-#50
sieunie Nov 11, 2024
90844db
Merge branch 'back/main' into feature/api/ordercancel-#51#52
sieunie Nov 11, 2024
3442786
📝 docs: swagger에 잘못 작성된 상태 코드 수정
uuuo3o Nov 11, 2024
a0534d6
⚙️ chore : deploy production(dev) yml 수정
jinddings Nov 11, 2024
115b1db
Merge branch 'back/main' into feature/api/stockDetail-#54
uuuo3o Nov 11, 2024
d9da239
➕ add : frontend .dokerignore 파일 추가
jinddings Nov 12, 2024
5d82ee6
⚙️ chore : docker ignore 추가
jinddings Nov 12, 2024
0f266d0
⚙️ chore: docker 멀티 스테이지 사용
jinddings Nov 12, 2024
41495ef
Merge pull request #70 from boostcampwm-2024/feature/api/stockbuy-#49
sieunie Nov 12, 2024
55e0ef9
Merge branch 'back/main' into feature/api/stocksell-#50
sieunie Nov 12, 2024
6915b77
Merge pull request #71 from boostcampwm-2024/feature/api/stocksell-#50
sieunie Nov 12, 2024
19973fd
Merge branch 'back/main' into feature/api/ordercancel-#51#52
sieunie Nov 12, 2024
f0d5127
Merge pull request #73 from boostcampwm-2024/feature/api/ordercancel-…
sieunie Nov 12, 2024
37e2351
Merge branch 'back/main' into feature/api/stockDetail-#54
uuuo3o Nov 12, 2024
efd8a34
Merge pull request #75 from boostcampwm-2024/feature/api/stockDetail-#54
uuuo3o Nov 12, 2024
0772d2e
🔧 fix: cors 문제 해결
uuuo3o Nov 12, 2024
8ca0758
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
uuuo3o Nov 12, 2024
9923b18
🔧 fix :login redirect 형식 수정(#7):
jinddings Nov 12, 2024
60544f0
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
jinddings Nov 12, 2024
fd6cab7
♻️ refactor : 사용하지 않는 import 제거
jinddings Nov 12, 2024
23c4f66
⚙️ chore : CI 코드 수정
jinddings Nov 12, 2024
8e12ab0
⚙️ chore : FE 디렉토리 cache-dependancy-path 수정
jinddings Nov 12, 2024
392d289
Merge pull request #80 from boostcampwm-2024/devops/ci
jinddings Nov 12, 2024
f40807b
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
jinddings Nov 12, 2024
788b002
♻️ refactor: BaseSocketService를 만들어 여러 개의 소켓 서비스를 쉽게 관리할 수 있도록 분리
uuuo3o Nov 12, 2024
4262fe5
⚙️ chore: 불필요한 import문 제거
uuuo3o Nov 12, 2024
d32a04c
Merge pull request #84 from boostcampwm-2024/feature/socket/stockDeta…
uuuo3o Nov 12, 2024
4c1250a
♻️ refactor: handleSocketData 추가
sieunie Nov 12, 2024
94364bb
✨ feat : 카카오 login 시에 등록되어 있지 않으면 User 정보 등록
jinddings Nov 12, 2024
eca8560
Merge pull request #85 from boostcampwm-2024/fix/socket
sieunie Nov 12, 2024
4c21122
➕ add : stockList controller, service, module 파일 생성
jinddings Nov 12, 2024
4096359
Merge branch 'feature/api/stockList-#57' of https://github.com/boostc…
jinddings Nov 12, 2024
16440dc
♻️ refactor: socket 분리 로직 수정
sieunie Nov 12, 2024
79a4902
⚙️ chore: lint 오류 해결
sieunie Nov 12, 2024
df7eb3b
⚙️ chore: lint 오류 다시 해결
sieunie Nov 12, 2024
437f622
⚙️ chore: TR_ID로 변수명 수정
sieunie Nov 12, 2024
890e447
⚙️ chore: 소켓 데이터 설명 주석 추가
sieunie Nov 12, 2024
02230c3
Merge pull request #91 from boostcampwm-2024/fix/socket
sieunie Nov 12, 2024
7a53c3f
✨feat: financeDataReader를 이용한 주식 목록 데이터 저장 스크립트 작성
jinddings Nov 12, 2024
26b9f66
✨ feat: 체결에 필요한 stock code 가져오기 위한 stock item 도메인 레이어 구현 #53
sieunie Nov 12, 2024
1a4d658
🔧 fix: stock_id를 stock_code로 변경
sieunie Nov 12, 2024
c8cc1c5
✨ feat: 체결 가능한 주문인지 확인하는 로직 구현 #53
sieunie Nov 12, 2024
3ca62ea
⚙️ chore: 소켓 모듈 import 업데이트 #53
sieunie Nov 12, 2024
4ae4780
✨ feat: 체결가 웹소켓과 주문 체결 연동 #53
sieunie Nov 12, 2024
426b752
🔧 fix: 매수/매도 메소드의 stock_id를 stock_code로 수정
sieunie Nov 12, 2024
4ac4733
✨ feat: 실시간 체결 내역 API에 사용할 DTO, interface 구현#55
uuuo3o Nov 12, 2024
afe6c79
✨ feat: 실시간 체결 내역 API 구현#55
uuuo3o Nov 12, 2024
c5db153
➕ add : stock Entity 생성 및 작성(#57)
jinddings Nov 12, 2024
9e32903
➕ add : stockListRepository 클래스 생성 및 작성(#57)
jinddings Nov 12, 2024
f545e67
✨ feat : 주식 리스트 가져오기 API 구현(#57)
jinddings Nov 12, 2024
57f6b6f
♻️ refactor : lint 오류 수정(#57)
jinddings Nov 12, 2024
92a6402
♻️ refactor : stockResponseDto 클래스 이름 변경 및 swagger doc을 위한 API Proper…
jinddings Nov 12, 2024
2d1ba00
♻️ refactor : swagger docs에 필수가 아닌 값 표시하게 수정
jinddings Nov 12, 2024
71f9f42
Merge pull request #86 from boostcampwm-2024/feature/api/login-#7
jinddings Nov 13, 2024
26855b9
Merge pull request #92 from boostcampwm-2024/feature/api/stockTradeHi…
uuuo3o Nov 13, 2024
100962d
Merge branch 'back/main' into feature/api/stockList-#57
jinddings Nov 13, 2024
10476c6
Merge pull request #93 from boostcampwm-2024/feature/api/stockList-#57
jinddings Nov 13, 2024
69c0ba5
🔧 fix: cors 오류 수정
uuuo3o Nov 13, 2024
8e690fa
Merge pull request #94 from boostcampwm-2024/fix/domain-cors
uuuo3o Nov 13, 2024
c570788
📝 docs : swagger 문서 Parameter 필수 수정
jinddings Nov 13, 2024
dc41849
➕ add: 소켓 로그 추가
sieunie Nov 13, 2024
f059980
Merge branch 'back/main' into feature/api/execute-#53
sieunie Nov 13, 2024
36356bf
🔧 fix : ssh 터널링을 이용해 NCP mysql에 데이터 수정하도록 변경
jinddings Nov 13, 2024
723fa19
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
jinddings Nov 13, 2024
cc95624
Merge pull request #96 from boostcampwm-2024/fix/socket-log
sieunie Nov 13, 2024
64d342c
Merge branch 'back/main' into feature/api/execute-#53
sieunie Nov 13, 2024
01e3293
🔥 remove: stock-item 도메인 삭제
sieunie Nov 13, 2024
eb204fd
🔧 fix: 주문 예약 시에만 웹소켓 구독하도록 로직 변경
sieunie Nov 13, 2024
f1f0c0b
♻️ refactor: stock index socket 디렉토리 위치 이동
sieunie Nov 13, 2024
0530c30
➕ add: 초기 실행 시 등록된 주문에 대해 웹소켓 구독
sieunie Nov 13, 2024
caf6a1a
➕ add: 체결 완료 되거나 취소된 주문 종목에 대해 구독 취소 로직 구현
sieunie Nov 13, 2024
7061ec1
➕ add: 주문 체결에 대한 로깅 추가 #53
sieunie Nov 13, 2024
8a4ec38
⚙️ chore: eslint 규칙 수정
sieunie Nov 13, 2024
2ee713d
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
jinddings Nov 13, 2024
e42261d
🚑 !HOTFIX: 로깅 오류 해결
sieunie Nov 13, 2024
98e432e
Merge branch 'back/main' into feature/api/execute-#53
sieunie Nov 13, 2024
a6b6ea6
✨ feat: 회원가입 시 assets table에도 row 추가되도록 트랜잭션 구현
sieunie Nov 13, 2024
e7ae190
✨ feat: API 분리를 위해 chart 전용으로 변경#54
uuuo3o Nov 13, 2024
5989e08
✨ feat: 프론트에서 필요한 값만 반환할 수 있도록 DTO 수정#54
uuuo3o Nov 13, 2024
b0b6d8d
🎨 style: 코드 순서 변경#54
uuuo3o Nov 13, 2024
153e023
🔥 remove: 불필요한 파일 삭제#54
uuuo3o Nov 13, 2024
c756172
📝 docs: 파일명 변경 및 swagger 문서 수정#54
uuuo3o Nov 13, 2024
a6eeef4
➕ add: 차트 그리기에 필요한 값 추가 및 인터페이스 이름 변경#54
uuuo3o Nov 13, 2024
99a94fa
🚚 rename: 중복되는 이름 변경#54
uuuo3o Nov 13, 2024
fc9a917
✨ feat: 주식 현재가 API에 사용할 interface, dto 구현#54
uuuo3o Nov 13, 2024
5f7d33c
✨ feat: 주식 현재가 API 요청 로직 구현#54
uuuo3o Nov 13, 2024
4910002
✨ feat: 주문 체결 시 자산 업데이트 로직 트랜잭션으로 구현 #53
sieunie Nov 13, 2024
16c34a5
🔧 fix: 프로그램 시작 시 종목 중복 구독 안되도록 로직 수정 #53
sieunie Nov 13, 2024
ea0afd5
Merge branch 'back/main' of https://github.com/boostcampwm-2024/web16…
jinddings Nov 13, 2024
3c650ac
♻️ refactor: requestApi 함수 분리 및 불필요한 파일 삭제#55
uuuo3o Nov 13, 2024
2fb460e
🚚 rename: 이름을 명확하게 변경#55
uuuo3o Nov 13, 2024
7012e9a
✨ feat: 주식현재가 일자별 API에 사용할 interface, dto 구현#55
uuuo3o Nov 13, 2024
4a686ac
✨ feat: 주식현재가 일자별 API 요청 로직 구현#55
uuuo3o Nov 13, 2024
0d2fc52
Merge pull request #95 from boostcampwm-2024/feature/api/stockList-#57
jinddings Nov 14, 2024
d814d9c
Merge pull request #99 from boostcampwm-2024/feature/api/stockDetail-#54
uuuo3o Nov 14, 2024
7aadb45
Merge pull request #101 from boostcampwm-2024/feature/api/stockTradeH…
uuuo3o Nov 14, 2024
0afe5b1
✨ feat : redis를 이용해 최근 검색 단어 저장(#57):
jinddings Nov 13, 2024
4ae58a8
🚑 !HOTFIX : 도커 컨테이너 시간 설정
jinddings Nov 14, 2024
9c0f980
🚑 !HOTFIX : docker 시간 설정 명령어 수정
jinddings Nov 14, 2024
128ddb1
🚑 !HOTFIX : docker 시간 설정 명령어 수정
jinddings Nov 14, 2024
7547bcb
🔧 fix : auth api 경로 변경
jinddings Nov 14, 2024
f19d30a
Merge pull request #103 from boostcampwm-2024/feature/api/login-#7
jinddings Nov 14, 2024
8276c03
🔧 fix: stock_balance 초기값 수정 및 rate 소수점 5자리까지 나타내도록 수정 #53
sieunie Nov 14, 2024
b0b13e6
🔧 fix: stock-order-socket과 stock-order 서비스가 순환참조 하지 않게 수정 #53
sieunie Nov 14, 2024
690d05a
⚙️ chore: lint 오류 수정 및 import/no-cycle 다시 on
sieunie Nov 14, 2024
d8280b7
Merge pull request #98 from boostcampwm-2024/feature/api/execute-#53
sieunie Nov 14, 2024
a617038
✨ feat: API 분리를 위해 chart 전용으로 변경#54
uuuo3o Nov 13, 2024
e23424b
✨ feat: 프론트에서 필요한 값만 반환할 수 있도록 DTO 수정#54
uuuo3o Nov 13, 2024
0203e65
🎨 style: 코드 순서 변경#54
uuuo3o Nov 13, 2024
00677ba
🔥 remove: 불필요한 파일 삭제#54
uuuo3o Nov 13, 2024
383a166
📝 docs: 파일명 변경 및 swagger 문서 수정#54
uuuo3o Nov 13, 2024
463c4cd
➕ add: 차트 그리기에 필요한 값 추가 및 인터페이스 이름 변경#54
uuuo3o Nov 13, 2024
764de7b
🚚 rename: 중복되는 이름 변경#54
uuuo3o Nov 13, 2024
98b8b57
✨ feat: 주식 현재가 API에 사용할 interface, dto 구현#54
uuuo3o Nov 13, 2024
4fe008b
✨ feat: 주식 현재가 API 요청 로직 구현#54
uuuo3o Nov 13, 2024
7dd9da8
♻️ refactor: requestApi 함수 분리 및 불필요한 파일 삭제#55
uuuo3o Nov 13, 2024
6df873c
🚚 rename: 이름을 명확하게 변경#55
uuuo3o Nov 13, 2024
875f2a7
✨ feat: 주식현재가 일자별 API에 사용할 interface, dto 구현#55
uuuo3o Nov 13, 2024
e56921a
✨ feat: 주식현재가 일자별 API 요청 로직 구현#55
uuuo3o Nov 13, 2024
7a61c8d
🚑 !HOTFIX : 도커 컨테이너 시간 설정
jinddings Nov 14, 2024
850e53b
🚑 !HOTFIX : docker 시간 설정 명령어 수정
jinddings Nov 14, 2024
5eb4fc5
🚑 !HOTFIX : docker 시간 설정 명령어 수정
jinddings Nov 14, 2024
e028917
🔧 fix : auth api 경로 변경(#57)
jinddings Nov 14, 2024
d218da8
🚚 rename : redisUtil -> redisDomainService로 클래스 및 파일 이름 변경(#57)
jinddings Nov 14, 2024
3bb0365
✨ feat : 최근 검색어 10 개만 저장하도록 수정(#57)
jinddings Nov 14, 2024
2b2b642
Merge branch 'back/main' into feature/api/stockList-#57
jinddings Nov 14, 2024
8c246af
✨ feat: 종목코드에 맞는 이름을 DB에서 꺼내와 보내주는 로직 구현#54
uuuo3o Nov 14, 2024
fb58cd8
🔧 fix: socket 데이터 안들어오면 연결 끊기는 현상 해결
sieunie Nov 14, 2024
b19180c
♻️ refactor : lint 오류 수정(#57)
jinddings Nov 14, 2024
6bd2c54
Merge branch 'feature/api/stockList-#57' of https://github.com/boostc…
jinddings Nov 14, 2024
8c644a8
Merge pull request #105 from boostcampwm-2024/feature/api/stockList-#57
jinddings Nov 14, 2024
30ced2f
➕ add: 연결 끊겼을때 로그 추가
sieunie Nov 14, 2024
6054b69
🔧 fix: koreaInvestmentService를 koreaInvetmentService로 오타냈던 부분 수정
uuuo3o Nov 14, 2024
1c5b993
🔧 fix: 빠져있던 await 추가
uuuo3o Nov 14, 2024
98fbae3
📝 docs: ApiTags 추가
uuuo3o Nov 14, 2024
e964e78
📝 docs: description 수정
uuuo3o Nov 14, 2024
639b19c
✨ feat : redis에 최근 검색어 저장하는 로직 Controller 분리(#57)
jinddings Nov 14, 2024
949f398
✨ feat : 배포 시에 redis container 실행 및 연결
jinddings Nov 14, 2024
6e73abe
🔧 fix : :Production Yml 파일도 수정
jinddings Nov 14, 2024
a897c8a
Merge pull request #109 from boostcampwm-2024/feature/api/stockList-#57
jinddings Nov 14, 2024
7c17c57
✨ feat: userStock domain 추가
sieunie Nov 14, 2024
e71c348
✨ feat: 주식 구매 체결 시 user_stocks 테이블 업데이트 로직 추가 #53
sieunie Nov 14, 2024
a727145
✨ feat : HttpExeption 에 대한 전역 필터 추가
jinddings Nov 14, 2024
e78d88e
🚑 !HOTFIX : 주식 검색에 대한 JWT guard 제거
jinddings Nov 14, 2024
032b692
Merge pull request #111 from boostcampwm-2024/feature/api/stockList-#57
jinddings Nov 14, 2024
30a57db
✨ feat: 주식 매도 체결 시 user_stocks 테이블 업데이트 #53
sieunie Nov 14, 2024
ae0e854
🔥 remove : filter 파일 삭제
jinddings Nov 14, 2024
4802fc3
🔧 fix : app.moudle에서 필터 삭제
jinddings Nov 14, 2024
d0d2943
✨ feat : HttpException Filter 구현
jinddings Nov 14, 2024
712cabd
⚙️ chore: 린트 오류 해결
sieunie Nov 14, 2024
7e209bc
Merge pull request #106 from boostcampwm-2024/fix/socket
sieunie Nov 14, 2024
7fc8e4e
Merge pull request #107 from boostcampwm-2024/feature/api/stockDetail…
uuuo3o Nov 14, 2024
0965f2d
Merge pull request #108 from boostcampwm-2024/refactor/jin/comment
uuuo3o Nov 14, 2024
ad6afbc
Merge pull request #113 from boostcampwm-2024/feature/api/execute-#53
sieunie Nov 14, 2024
2af524c
🚑 !HOTFIX: 핑퐁 로직 수정
sieunie Nov 14, 2024
146f4ae
Merge pull request #114 from boostcampwm-2024/refactor/jindding/HttpE…
jinddings Nov 14, 2024
f07ecea
🔧 fix: controller 주소 수정
uuuo3o Nov 14, 2024
143e5fa
Merge pull request #117 from boostcampwm-2024/fix/controller-url
uuuo3o Nov 14, 2024
6efbd2c
🚑 !HOTFIX : kakao callbackURL 수정
jinddings Nov 14, 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
4 changes: 2 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
push:
branches: [back/main, front/main]
pull_request:
branches: [main, back/main, dev]
branches: [back/main, front/main]

jobs:
BE-test-and-build:
Expand Down Expand Up @@ -49,7 +49,7 @@ jobs:
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: ./BE/package-lock.json
cache-dependency-path: ./FE/package-lock.json

- name: Install dependencies
working-directory: ./FE
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: deploy

on:
push:
branches: [main, alpha]
branches: [dev]
pull_request:
branches: [main, alpha]
branches: [dev]

env:
DOCKER_IMAGE: ${{ vars.DOCKERHUB_USERNAME }}/juga-docker
Expand All @@ -13,38 +13,48 @@ env:
jobs:
build-and-deploy:
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
app:
[
{ name: 'be', dir: 'BE', port: 3000, container: 'juga-docker-be' },
{ name: 'fe', dir: 'FE', port: 5173, container: 'juga-docker-fe' },
]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: ./BE/package-lock.json
cache-dependency-path: ./${{matrix.app.dir}}/package-lock.json

- name: Create .env file
run: |
touch ./BE/.env
echo "${{ secrets.ENV }}" > ./BE/.env
touch ./${{ matrix.app.dir }}/.env
echo "${{ secrets.ENV }}" > ./${{matrix.app.dir}}/.env

- name: Install dependencies
working-directory: ./BE
working-directory: ./${{matrix.app.dir}}
continue-on-error: true
run: npm ci

- name: Run tests
working-directory: ./BE
if: ${{ matrix.app.name == 'be' }}
working-directory: ./${{matrix.app.dir}}
run: npm test
env:
CI: true

- name: Run linter
working-directory: ./BE
working-directory: ./${{matrix.app.dir}}
run: npm run lint

- name: Build application
working-directory: ./BE
working-directory: ./${{matrix.app.dir}}
run: npm run build

- name: Login to Docker Hub
Expand All @@ -54,16 +64,16 @@ jobs:
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and Push Docker Image
working-directory: ./BE
working-directory: ./${{ matrix.app.dir }}
env:
NCP_ACCESS_KEY: ${{ secrets.NCP_ACCESS_KEY }}
NCP_SECRET_KEY: ${{ secrets.NCP_SECRET_KEY }}
run: |
docker build -t ${{ env.DOCKER_IMAGE }}:${{ env.DOCKER_TAG }} .
docker tag ${{ env.DOCKER_IMAGE }}:${{ env.DOCKER_TAG }} ${{ env.DOCKER_IMAGE }}:latest
docker build -t ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }} .
docker tag ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }} ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:latest

docker push ${{ env.DOCKER_IMAGE }}:${{ env.DOCKER_TAG }}
docker push ${{ env.DOCKER_IMAGE }}:latest
docker push ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }}
docker push ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:latest

- name: Get Github Actions IP
id: ip
Expand Down Expand Up @@ -95,15 +105,25 @@ jobs:
script: |
docker system prune -af
echo "${{ secrets.ENV }}" > .env

docker pull ${{ env.DOCKER_IMAGE }}:${{ env.DOCKER_TAG }}
docker stop juga-docker || true
docker rm juga-docker || true

docker network create juga-network || true

docker run -d \
--name redis \
--network juga-network \
-p 6379:6379 \
-v redis_data:/data \
redis:latest redis-server --appendonly yes

docker pull ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }}
docker stop ${{ matrix.app.container }} || true
docker rm ${{ matrix.app.container }} || true
docker run -d \
--name juga-docker \
-p 3000:3000 \
--name ${{ matrix.app.container }} \
--network juga-network \
-p ${{ matrix.app.port }}:${{ matrix.app.port }} \
--env-file .env \
${{ env.DOCKER_IMAGE }}:${{ env.DOCKER_TAG }}
${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }}

- name: Remove Github Action Ip to Security group
run: |
Expand Down
132 changes: 132 additions & 0 deletions .github/workflows/deply-alpha.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@
name: deploy

on:
push:
branches: [alpha]
pull_request:
branches: [alpha]

env:
DOCKER_IMAGE: ${{ vars.DOCKERHUB_USERNAME }}/juga-docker
DOCKER_TAG: ${{ github.sha }}

jobs:
build-and-deploy:
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
app:
[
{ name: 'be', dir: 'BE', port: 3000, container: 'juga-docker-be' },
{ name: 'fe', dir: 'FE', port: 5173, container: 'juga-docker-fe' },
]

steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: ./${{matrix.app.dir}}/package-lock.json

- name: Create .env file
run: |
touch ./${{ matrix.app.dir }}/.env
echo "${{ secrets.ENV }}" > ./${{matrix.app.dir}}/.env

- name: Install dependencies
working-directory: ./${{matrix.app.dir}}
continue-on-error: true
run: npm ci

- name: Run tests
if: ${{ matrix.app.name == 'be' }}
working-directory: ./${{matrix.app.dir}}
run: npm test
env:
CI: true

- name: Run linter
working-directory: ./${{matrix.app.dir}}
run: npm run lint

- name: Build application
working-directory: ./${{matrix.app.dir}}
run: npm run build

- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ vars.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and Push Docker Image
working-directory: ./${{ matrix.app.dir }}
env:
NCP_ACCESS_KEY: ${{ secrets.NCP_ACCESS_KEY }}
NCP_SECRET_KEY: ${{ secrets.NCP_SECRET_KEY }}
run: |
docker build -t ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }} .
docker tag ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }} ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:latest

docker push ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }}
docker push ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:latest

- name: Get Github Actions IP
id: ip
uses: haythem/[email protected]

- name: Setting NCP CLI & Credentials
run: |
cd ~
wget https://www.ncloud.com/api/support/download/5/65
unzip 65
mkdir ~/.ncloud
echo -e "[DEFAULT]\nncloud_access_key_id = ${{ secrets.NCP_ACCESS_KEY }}\nncloud_secret_access_key = ${{ secrets.NCP_SECRET_KEY }}\nncloud_api_url = ${{ secrets.NCP_API_URI }}" >> ~/.ncloud/configure

- name: Add Github Action Ip to Security group
run: |
cd ~
ls -la
chmod -R 777 ~/cli_linux
cd ~/cli_linux
./ncloud vserver addAccessControlGroupInboundRule --regionCode KR --vpcNo ${{ secrets.NCP_VPC_ID }} --accessControlGroupNo ${{ secrets.NCP_ACG_ID }} --accessControlGroupRuleList "protocolTypeCode='TCP', ipBlock='${{ steps.ip.outputs.ipv4 }}/32', portRange='${{ secrets.SSH_PORT }}'"

- name: Deploy to NCP Server
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.NCP_ALPHA_SERVER_HOST }}
username: ${{ secrets.NCP_ALPHA_SERVER_USERNAME }}
key: ${{ secrets.NCP_SERVER_SSH_KEY }}
port: 22
script: |
docker system prune -af
echo "${{ secrets.ENV }}" > .env

docker network create juga-network || true

docker run -d \
--name redis \
--network juga-network \
-p 6379:6379 \
-v redis_data:/data \
redis:latest redis-server --appendonly yes

docker pull ${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }}
docker stop ${{ matrix.app.container }} || true
docker rm ${{ matrix.app.container }} || true
docker run -d \
--name ${{ matrix.app.container }} \
--network juga-network \
-p ${{ matrix.app.port }}:${{ matrix.app.port }} \
--env-file .env \
${{ env.DOCKER_IMAGE }}-${{ matrix.app.name }}:${{ env.DOCKER_TAG }}

- name: Remove Github Action Ip to Security group
run: |
chmod -R 777 ~/cli_linux
cd ~/cli_linux
./ncloud vserver removeAccessControlGroupInboundRule --regionCode KR --vpcNo ${{ secrets.NCP_VPC_ID }} --accessControlGroupNo ${{ secrets.NCP_ACG_ID }} --accessControlGroupRuleList "protocolTypeCode='TCP', ipBlock='${{ steps.ip.outputs.ipv4 }}/32', portRange='${{ secrets.SSH_PORT }}'"
1 change: 1 addition & 0 deletions BE/.dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
Dockerfile
node_modules
dist
.env*
1 change: 1 addition & 0 deletions BE/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,6 @@ module.exports = {
'class-methods-use-this': 'off',
'@typescript-eslint/no-unsafe-assignment': 'off',
'@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/naming-convention': 'off',
},
};
19 changes: 14 additions & 5 deletions BE/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
FROM node:20
RUN mkdir -p /var/app
WORKDIR /var/app
COPY . .
# 빌드 스테이지
FROM node:20-slim as builder
WORKDIR /app
COPY package*.json ./
RUN npm install
COPY . .
RUN npm run build

# 실행 스테이지
FROM node:20-slim
WORKDIR /var/app
COPY package*.json ./
RUN npm install --only=production
COPY --from=builder /app/dist ./dist

EXPOSE 3000
CMD [ "node", "dist/main.js" ]
CMD ["node", "dist/main.js"]
27 changes: 27 additions & 0 deletions BE/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
version: '3'
services:
api:
build:
context: .
dockerfile: Dockerfile
ports:
- '3000:3000'
environment:
- NODE_ENV=production
- REDIS_HOST=redis
- REDIS_PORT=6379
depends_on:
- redis
restart: unless-stopped

redis:
image: redis:latest
ports:
- '6379:6379'
volumes:
- redis_data:/data
command: redis-server --appendonly yes
restart: unless-stopped

volumes:
redis_data:
Loading
Loading