Skip to content

Commit

Permalink
Merge pull request #40 from reading-log/main
Browse files Browse the repository at this point in the history
main 변경점 develop 브랜치에 병합
  • Loading branch information
don9m1n authored Mar 22, 2024
2 parents 587eb32 + 6ec56dc commit 771aa22
Show file tree
Hide file tree
Showing 7 changed files with 31 additions and 43 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/work.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 'work'
name: 'readinglog-ci/cd'

on:
push:
Expand Down Expand Up @@ -68,5 +68,8 @@ jobs:
script: |
sudo docker login -u ${{ secrets.DOCKER_HUB_USERNAME }} -p ${{ secrets.DOCKER_HUB_PASSWORD }}
sudo docker pull ${{ secrets.DOCKER_REPO }}
sudo docker stop readinglog_app || true
sudo docker rm readinglog_app || true
sudo docker run --name=readinglog_app --restart unless-stopped \
-p 8080:8080 -e TZ=Asia/Seoul -d ${{ secrets.DOCKER_REPO }}
sudo docker image prune -f
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# 📚 Reading Log
- `프로젝트 소개:` 내가 읽은 책들을 기록하는 독서 기록 서비스
# 📚 Reading Log (리딩로그)
- `프로젝트 소개:` 내가 읽은 책들을 기록하는 독서 기록 서비스.
- `개발 기간:` 2024.03.03. ~
___

Expand Down
4 changes: 3 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-webflux'

/* Database */
runtimeOnly 'com.h2database:h2'
//runtimeOnly 'com.h2database:h2'
runtimeOnly 'com.mysql:mysql-connector-j'

/* Testing */
Expand All @@ -51,6 +51,8 @@ dependencies {
implementation 'io.jsonwebtoken:jjwt-api:0.11.5'
implementation 'io.jsonwebtoken:jjwt-impl:0.11.5'
implementation 'io.jsonwebtoken:jjwt-jackson:0.11.5'

implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.2.0'
}

tasks.named('bootBuildImage') {
Expand Down
21 changes: 21 additions & 0 deletions src/main/java/com/api/readinglog/common/web/WebConfig.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
package com.api.readinglog.common.web;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.CorsRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

@Configuration
public class WebConfig implements WebMvcConfigurer {

@Override
public void addCorsMappings(CorsRegistry registry) {
// TODO: cors 설정 좀 더 다듬기
registry.addMapping("/**")
.allowedOriginPatterns("*")
.allowedHeaders("*")
.allowedMethods("*")
.exposedHeaders("*")
.allowCredentials(true)
.maxAge(3600); // 캐싱
}
}
7 changes: 0 additions & 7 deletions src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,15 @@ spring:
active: dev

jpa:
hibernate:
ddl-auto: create
show-sql: true
properties:
hibernate:
format_sql: true
defer-datasource-initialization: true

h2:
console:
enabled: true

sql:
init:
mode: always

logging:
level:
root: info
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;

@SpringBootTest
//@SpringBootTest
class ReadinglogApplicationTests {

@Test
Expand Down
31 changes: 0 additions & 31 deletions src/test/java/com/api/readinglog/domain/entity/MemberTest.java

This file was deleted.

0 comments on commit 771aa22

Please sign in to comment.