Skip to content
This repository has been archived by the owner on Nov 8, 2023. It is now read-only.

Mobile web to give all users a special experiance where they can record a video with truthful message and send it in the future to the one who they love

License

Notifications You must be signed in to change notification settings

Scriptfarmes/video-messenger-timeletter

ย 
ย 

Repository files navigation

Team 5

Team name: ์บํ„ฐํ”ผ๐Ÿ›

Time Letter ๐Ÿ“ฎ

| ํƒ€์ž„๋ ˆํ„ฐ :: ๋‹น์‹ ์˜ ์ถ”์–ต์„ ๊ฐ„์งํ•ด๋“œ๋ฆฝ๋‹ˆ๋‹ค. ๋ฏธ๋ž˜์˜ ๋‹น์‹ ๊ณผ ์†Œํ†ตํ•˜๋Š” ๊ธธ. ํƒ€์ž„๋ ˆํ„ฐโฑ

๋กœ๊ณ -removebg-preview

๋ฉ”์ธ Page

๋ ˆํ„ฐ ์ƒ์„ฑ ํŽ˜์ด์ง€

์กฐํšŒ ํŽ˜์ด์ง€

๊ทธ๋ฃน ํŽ˜์ด์ง€

๋งˆ์ด ํŽ˜์ด์ง€


๐Ÿ” What's TimeLetter

Time Capsule๊ณผ Letter์˜ ํ•ฉ์„ฑ์–ด

์†Œ์ค‘ํ•œ ์ถ”์–ต์„ ๋‹ด์•„ ๋ฏธ๋ž˜๋กœ ๋ณด๋‚ด๋Š” ๋น„๋™์‹œ์„ฑ ๋ฉ”์‹œ์ง• ์„œ๋น„์Šค

๐Ÿ“ Features

  1. ๋ ˆํ„ฐ ์ƒ์„ฑ๊ธฐ๋Šฅ

    • ์˜์ƒ ์—…๋กœ๋“œ
      • ํœด๋Œ€ํฐ์—์„œ ์ดฌ์˜ํ•œ ์˜์ƒ ๋ฐ ์•จ๋ฒ”์— ์ €์žฅ๋œ ์˜์ƒ ์—…๋กœ๋“œ
    • ์˜คํ”ˆ ์กฐ๊ฑด ์„ค์ •
      • ์˜คํ”ˆํ•  ๋‚ ์งœ ์ง€์ •
    • ์ถ”์–ต์˜ ์žฅ์†Œ ์ €์žฅ
      • kakao map์„ ํ†ตํ•ด ๊ธฐ์–ตํ•˜๊ณ  ์‹ถ์€ ์žฅ์†Œ ์ €์žฅ
  2. ๋ ˆํ„ฐ ์กฐํšŒ

    • ๋ ˆํ„ฐ ์ƒ์„ฑ ์‹œ ๋ ˆํ„ฐ ์‹๋ณ„์ž๋กœ ์‚ฌ์šฉ๋˜๋Š” ๊ณ ์œ  ํ† ํฐ์„ ๋ฐœ๊ธ‰
    • ์˜คํ”ˆ/๋น„์˜คํ”ˆ ๋ ˆํ„ฐ๋ฅผ ๊ตฌ๋ณ„ํ•˜์—ฌ ๋ณธ์ธ์—๊ฒŒ ์ƒ์„ฑ๋œ ๋ ˆํ„ฐ ์ œ๊ณต
  3. ๊ทธ๋ฃน ๊ธฐ๋Šฅ

    • ๋ฉค๋ฒ„ ์ถ”๊ฐ€
      • ์ด๋ฆ„์œผ๋กœ ๋ฉค๋ฒ„ ๊ฒ€์ƒ‰
  4. ์•Œ๋ฆผ ๊ธฐ๋Šฅ

    • ์„œ๋ฒ„์—์„œ ๋ถ„ ๋‹จ์œ„๋กœ ๋ ˆํ„ฐ ํ™•์ธ ํ›„ ์•Œ๋ฆผ ์ „์†ก
    • ์‚ฌ์ดํŠธ ๋‚ด๋ถ€ ์•Œ๋ฆผ
      • ์•Œ๋ฆผ ๋ฒ„ํŠผ์œผ๋กœ ์กฐํšŒ
    • ๋ฌธ์ž ๋ฉ”์‹œ์ง€
      • ์˜คํ”ˆ ๋‚ ์งœ์— ๋ฌธ์ž ๋ฉ”์‹œ์ง€ ๋ฐœ์†ก
  5. ๋ชจ๋ฐ”์ผ ํ˜ธํ™˜

    • ios, andriod, windows ๊ฐ„์˜ ํ˜ธํ™˜ ๊ฐ€๋Šฅ
  • [์•Œ๋ฆผ ๊ธฐ๋Šฅ]

๐ŸŒ Browser Support

Chrome Chrome IE Internet Explorer Edge Edge Safari Safari Firefox Firefox
Yes 10+ Yes Yes Yes

๐Ÿ“‚Tech Stack

Tools

Tool ๊ธฐ์ˆ 
GitLab ๊ธฐ๋Šฅ๋ณ„ branch๋ฅผ ๋‚˜๋ˆ ์„œ ์ฝ”๋“œ ๋ฒ„์ „ ๊ด€๋ฆฌ
Jira Issue ๊ด€๋ฆฌ๋ฅผ ์œ„ํ•ด Git๊ณผ ์—ฐ๋™ํ•˜์—ฌ ์‚ฌ์šฉ
Scrum Poker Jira Issue ๋ณ„ ์Šคํ”„๋ฆฐํŠธ ์‹œ๊ฐ„ ๊ด€๋ฆฌ๋ฅผ ์œ„ํ•œ ์–ดํ”Œ๋ฆฌ์ผ€์ด์…˜
VS Code code ๊ตฌํ˜„์„ ์œ„ํ•œ Tool
Google Chrome ๊ตฌํ˜„ํ•œ ํ™”๋ฉด์„ ์ถœ๋ ฅํ•˜๊ธฐ ์œ„ํ•œ ๋ธŒ๋ผ์šฐ์ €

โ—พ Library

Library ๋‚ด์šฉ
Spring Backend ๊ตฌํ˜„์„ ์œ„ํ•œ Java web framework
React Frontend ๊ตฌํ˜„์„ ์œ„ํ•œ JavaScript framework

โ—พ Software Language

Language ๊ธฐ์ˆ 
Java Backend ๊ตฌํ˜„ ์–ธ์–ด
JavaScript Frontend ๊ตฌํ˜„ ์–ธ์–ด
HTML/CSS Frontend ๊ตฌํ˜„ ์–ธ์–ด

๐Ÿ”ง Architecture

Entitiy Relationship Diagram

img

Sequence Diagrams

  • ๋กœ๊ทธ์ธ

erd

  • ํšŒ์›๊ฐ€์ž…

erd

  • ID/PW ์ฐพ๊ธฐ

erd

  • ์บก์Š์ƒ์„ฑ ๋ฐ ์กฐํšŒ

![erd](docs/assets/Sequence_์บก์Š์ƒ์„ฑ ๋ฐ ์กฐํšŒ.png)

  • ๊ทธ๋ฃน๊ด€๋ฆฌ

erd

๐Ÿ“ฆ Packages (M)

Frontend

Name Description
"@material-ui/core" React components for faster and simpler web development. Build your own design system, or start with Material Design
"@material-ui/icons" This package provides the Google Material icons packaged as a set of React components.
"@material-ui/lab" This package hosts the incubator components that are not yet ready to move to core.
"@reduxjs/toolkit" This package hosts the incubator components that are not yet ready to move to core.
"@testing-library/jest-dom" Custom jest matchers to test the state of the DOM
"@testing-library/react" Simple and complete React DOM testing utilities that encourage good testing practices.
"antd" An enterprise-class UI design language and React UI library.
"axios" Promise based HTTP client for the browser and node.js
"gsap" GSAP is a robust JavaScript toolset that turns developers into animation superheroes
"howler" howler.js is an audio library for the modern web
"moment" A JavaScript date library for parsing, validating, manipulating, and formatting dates.
"node-sass" Node-sass is a library that provides binding for Node.js to LibSass, the C version of the popular stylesheet preprocessor, Sass.
"react-device-detect" Detect device, and render view according to the detected device type.
"react-dom" This package serves as the entry point to the DOM and server renderers for React
"react-scripts" This package includes scripts and configuration used by Create React App. Please refer to its documentation:
"react-howler" A React.js wrapper for howler.js (audio player).
"sweetalert" A beautiful replacement for JavaScript's "alert"

Backend

Name Description
$mysql MySQL connector
$lombok getter, setter, toString ๋“ฑ์˜ ๋ฉ”์„œ๋“œ ์ž‘์„ฑ ์ฝ”๋“œ๋ฅผ ์ค„์—ฌ์ฃผ๋Š” ์ฝ”๋“œ ๋‹ค์ด์–ดํŠธ ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ
$jjwt JWT ํ† ํฐ ์ƒ์„ฑ ๋ฐ JWT ํ† ํฐ ํŒŒ์‹ฑ, ๊ฒ€์ฆ์„ ํ•ด์ฃผ๋Š” ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ
$json JavaScript Object Notation; ๊ฒฝ๋Ÿ‰(Lightweight)์˜ DATA-๊ตํ™˜ ํ˜•์‹
$jackson JSON Convertor(์ปจํŠธ๋กค๋Ÿฌ์—์„œ ์ „๋‹ฌํ•œ DTO๋ฐ์ดํ„ฐ๋ฅผ JSON์œผ๋กœ ๋ณ€๊ฒฝํ•˜๊ธฐ ์œ„ํ•ด ์‚ฌ
$swagger REST ์›น ์„œ๋น„์Šค๋ฅผ ์„ค๊ณ„, ๋นŒ๋“œ, ๋ฌธ์„œํ™”, ์†Œ๋น„ํ•˜๋Š” ์ผ์„ ๋„์™€์ฃผ๋Š” ๋Œ€ํ˜• ๋„๊ตฌ ์ƒํƒœ๊ณ„์˜ ์ง€์›์„ ๋ฐ›๋Š” ์˜คํ”ˆ ์†Œ์Šค ์†Œํ”„ํŠธ์›จ์–ด

๐Ÿ“š ์ค€๋น„ํ•˜๊ธฐ

DB ์ƒ์„ฑํ•˜๊ณ  ์„ค์ • ํŒŒ์ผ application.properties(๋ฐฑ์—”๋“œ), .env(ํ”„๋ก ํŠธ์—”๋“œ) ํŒŒ์ผ ์ƒ์„ฑ ๋ฐ ์ถ”๊ฐ€ํ•˜์‹œ๋ฉด ๋ฉ๋‹ˆ๋‹ค

  1. Git clone ๋ฐ›๊ธฐ
git clone https://lab.ssafy.com/s04-bigdata-sub3/s04p23d106.git
  1. ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค ์ค€๋น„
  • 'timeletter' ํ…Œ์ดํ„ฐ๋ฒ ์ด์Šค ์ƒ์„ฑ
CREATE SCHEMA `timeletter`;
  • ํ•„์š”ํ•œ ํ…Œ์ด๋ธ” ์ƒ์„ฑ

Database Tables

  1. [Backend] application.properties ์„ค์ •
  • backend\src\main\resources ํด๋” ์•„๋ž˜ ์ƒ์„ฑํ•˜์‹œ๋ฉด ๋ฉ๋‹ˆ๋‹ค
  • mysql ๋„๋ฉ”์ธ๊ณผ ์•„์ด๋””/๋น„๋ฒˆ ์ž‘์„ฑ
server:
	servlet:
		context-path: /timeletter

# fileupload 
spring:
	servlet:
		multipart:
			enabled:true
			max-file-size:500MB
			max-request-size:500MB
	datasource:
        driver-class-name: com.mysql.cj.jdbc.Driver
        url: jdbc:mysql://k4d105.p.ssafy.io/timeletter?serverTimeZone=UTC&CharacterEncoding=UTF-8
        username: caterpie
        password: password
	jpa:
        hibernate:
        	ddl-auto: none
        show-sql: false
        properties:
        	hibernate:
        		format_sql: true        
       
# jwt
jwt:
  header: Authorization
  secret: dGltZWxldHRlci1pcy1hLXNsb3ctbWVzc2FuZ2VyLXBsYXRmb3JtLXNlcnZpY2VkLWJ5LXRlYW0tY2F0ZXJwaWUtc2luY2UtMjAyMS1hbGwtcmlnaHRzLXJlc2VydmVkLWF0LWNhdGVycGllCg==
  token-validity-in-seconds: 86400

# logging
logging:
  level:
    com.caterpie: DEBUG
  1. [Frontend] .env ์ž‘์„ฑ
  • frontend ํด๋” ์•„๋ž˜ ์ƒ์„ฑํ•˜์‹œ๋ฉด ๋ฉ๋‹ˆ๋‹ค
  • nginx์— ๋ช…์‹œ๋œ location์„ ๋”ฐ๋ผ๊ฐ‘๋‹ˆ๋‹ค
React_APP_SERVER_URL={๋„๋ฉ”์ธ์ฃผ์†Œ}
React_APP_SPRING_URL={๋„๋ฉ”์ธ์ฃผ์†Œ}/timeletter
React_APP_STORAGE_URL={๋„๋ฉ”์ธ์ฃผ์†Œ}/videos
  1. [Frontend] ๋ชจ๋“ˆ ๋‹ค์šด๋กœ๋“œ
# frontend ํด๋”๋กœ ์ด๋™ํ•ด์„œ ๋‹ค์šด
cd frontend/
npm install
  1. [Backend] (Option) Spring boot๋ฅผ build(jar ํŒŒ์ผ ์ƒ์„ฑ)
# backend ํด๋”๋กœ ์ด๋™ํ•ด์„œ Spring boot jar ํŒŒ์ผ ์ƒ์„ฑ
cd backend/build/libs
./gradlew bootJar

๐Ÿ ์‹คํ–‰ํ•˜๊ธฐ

  1. ๋ฐฑ์—”๋“œ ์‹คํ–‰
  • ์ƒ์„ฑํ•œ jar ํŒŒ์ผ ์‹คํ–‰
java -jar [filename].jar //timeletter.jar
  • ํ˜น์€ war ํŒŒ์ผ ์ƒ์„ฑํ•˜์ง€ ์•Š๊ณ  demon์œผ๋กœ ๋กœ์ปฌ์—์„œ ์‹คํ–‰ํ•˜๊ณ  ์‹ถ๋‹ค๋ฉด STS์™€ ๊ฐ™์€ IDEA์—์„œ Spring boot Run์„ ์‹คํ–‰ํ•˜๊ฑฐ๋‚˜ ์•„๋ž˜ ๋ช…๋ น์–ด๋ฅผ ํ†ตํ•ด ์‹คํ–‰
mvn spring-boot:run
  1. ํ”„๋ก ํŠธ์—”๋“œ ์‹คํ–‰
  • ํŒจํ‚ค์ง€ ์„ค์น˜
$ npm i
  • React ์‹คํ–‰
npm start

๐Ÿ–ฅ ๋ฐฐํฌํ•˜๊ธฐ

ํ•ด๋‹น ์„œ๋น„์Šค๋Š” AWS EC2๋ฅผ ํ†ตํ•ด ๋ฐฐํฌํ•˜์˜€๊ณ  Docker์™€ Jenkins๋ฅผ ์ด์šฉํ•ด CI/CD ๊ตฌ์ถ•ํ•˜์˜€์Šต๋‹ˆ๋‹ค:

  1. AWS EC2 ์ธ์Šคํ„ด์Šค ์ƒ์„ฑ (ubuntu)
  2. docker ์„ค์น˜
  3. ํ•„์š”ํ•œ ์ด๋ฏธ์ง€๋ฅผ docker hub๋ฅผ ํ†ตํ•ด ์„ค์น˜
    1. Jenkins
    2. MySQL
  4. docker-compose.yml ์ž‘์„ฑ(services - jenkins, db, frontend network: caterpie)
  5. Jenkins์™€ Gitlab repository ์—ฐ๋™
  6. MySQL ์ปจํ…Œ์ด๋„ˆ์— timeletter DB ์Šคํ‚ค๋งˆ ์ƒ์„ฑ
  7. Nginx ์„ค์ • (frontend/nginx ํด๋”์˜ default.conf)
  8. frontend, backend ํด๋” ์•ˆ์— dockerfile ์ž‘์„ฑ
  9. ํ”„๋กœ์ ํŠธ root ์œ„์น˜์— Jenkins ํŒŒ์ผ ์ž‘์„ฑ
    1. Build and Test ๊ณผ์ •
    2. Build (frontend, backend)
    3. Run (์ปจํ…Œ์ด๋„ˆ ์‹คํ–‰)
  10. docker ps ๋ฅผ ํ†ตํ•ด frontend, backend, django ์ปจํ…Œ์ด๋„ˆ๊ฐ€ ์‹คํ–‰๋˜๋Š” ๊ฒƒ์„ ํ™•์ธ (Jenkins, MySQL ํฌํ•จ)

๐Ÿ’ฌ Documents

๐Ÿ‘ฅ Contributer

  • ์•ˆ์„ธ์ต(FE)
  • ์ด๋Œ€ํ—Œ(FE)
  • ์ดํ˜œ์ง„(FE)
  • ์žฅ๋ฏผํ˜ธ(BE)
  • ์กฐํ˜„์„ญ(BE)

๐Ÿš€ References

๐Ÿ“œ License

This software is licensed under the MIT ยฉ SSAFY.

About

Mobile web to give all users a special experiance where they can record a video with truthful message and send it in the future to the one who they love

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 53.2%
  • Java 30.7%
  • CSS 6.3%
  • Roff 3.9%
  • SCSS 2.9%
  • Batchfile 1.7%
  • Other 1.3%