20. JWT위한 yml파일 세팅
by 볼빵빵오춘기yml 설정(feat. properties파일 설정)
영상에서는 yml 설정하였으나 나는 기존에 쓰던 properties파일을 하여 yml로 하지않고 properties파일로 설정하였다.
#h2 console
spring.h2.console.enabled=true
spring.h2.console.path=/h2-console
#h2 db
spring.datasource.url=jdbc:h2:tcp://localhost/~/test;DATABASE_TO_UPPER=TURE
spring.datasource.driverClassName=org.h2.Driver
spring.datasource.username=sa
spring.datasource.password=
spring.jpa.database-platform=org.hibernate.dialect.H2Dialect
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.H2Dialect
#hibernate
spring.jpa.properties.hibernate.format_sql=true
spring.jpa.properties.hibernate.show_sql=true
spring.jpa.hibernate.ddl-auto=create
spring.jpa.hibernate.naming.physical-strategy=org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
RestApiController.java
controller 패키지 생성 후 RestApiController.java 생성 및 코드 추가한다.
@RestController
public class RestApiController {
@GetMapping("/home")
public String home(){
return "<h1>home</h1>";
}
}
'강의 따라하기 > JWT' 카테고리의 다른 글
22. JWT Bearer 인증 방식 (0) | 2024.08.25 |
---|---|
21. JWT를 위한 security 설정 (0) | 2024.08.25 |
19. JWT 프로젝트 세팅 (0) | 2024.08.25 |
18. JWT 구조이해 (0) | 2024.08.24 |
17. JWT를 이해하기전 RFC문서란 (0) | 2024.08.24 |
블로그의 정보
Hello 춘기's world
볼빵빵오춘기