인메모리 DB로 테스트 하는 yml, maven
<dependency >
<groupId >com.h2database</groupId >
<artifactId >h2</artifactId >
<scope >runtime</scope >
</dependency >
server :
port : 8080
servlet :
context-path : /
encoding :
charset : utf-8
enabled : true
spring :
mvc :
view :
prefix : /WEB-INF/views/
suffix : .jsp
datasource :
url : jdbc:h2:mem:test;MODE=MySQL
driver-class-name : org.h2.Driver
username : sa
password :
h2 :
console :
enabled : true
jpa :
open-in-view : true
hibernate :
ddl-auto : create # update <- 서버 데이터 유지 / create <- 사라짐 / none <- 아무것도 변경 못하게... / create-drop도 있는데 몰라도 된다고...
naming :
physical-strategy : org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
show-sql : true
servlet :
multipart : # multipart 스타일로 사진을 받겠다.
enabled : true # true <- 사진을 받겠다.
max-file-size : 2MB # 사진 최대 용량은 2MB가 넘지 않도록 제한
security :
user :
name : test
password : 1234
file : # 내가 만든 키값
path : C:/workspace/upload/ # 업로드된 사진 저장할 공간(폴더)
Sring Boot DevTools
Lombok
Spring Data JPA
MariaDB Driver
Spring Security
Spring Web
oauth2-client
<!-- 시큐리티 태그 라이브러리 -->
<dependency >
<groupId >org.springframework.security</groupId >
<artifactId >spring-security-taglibs</artifactId >
</dependency >
<!-- JSP 템플릿 엔진 -->
<dependency >
<groupId >org.apache.tomcat</groupId >
<artifactId >tomcat-jasper</artifactId >
<version >9.0.43</version >
</dependency >
<!-- JSTL -->
<dependency >
<groupId >javax.servlet</groupId >
<artifactId >jstl</artifactId >
</dependency >
<dependency >
<groupId >org.springframework.boot</groupId >
<artifactId >spring-boot-starter-aop</artifactId >
</dependency >
<dependency >
<groupId >org.springframework.boot</groupId >
<artifactId >spring-boot-starter-validation</artifactId >
</dependency >
create user 'cos '@' %' identified by ' cos1234' ;
GRANT ALL PRIVILEGES ON * .* TO ' cos' @' %' ;
create database photogram ;
server :
port : 8080
servlet :
context-path : /
encoding :
charset : utf-8
enabled : true
spring :
mvc :
view :
prefix : /WEB-INF/views/
suffix : .jsp
datasource :
driver-class-name : org.mariadb.jdbc.Driver
url : jdbc:mariadb://localhost:3306/costa?serverTimezone=Asia/Seoul
username : costa
password : costa1234
jpa :
open-in-view : true
hibernate :
ddl-auto : update
naming :
physical-strategy : org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
show-sql : true
servlet :
multipart :
enabled : true
max-file-size : 2MB
security :
user :
name : test
password : 1234
file :
path : C:/src/springbootwork-sts/upload/
<%@ taglib prefix =" c" uri =" http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix =" sec" uri =" http://www.springframework.org/security/tags" %>