[SpringBoot - 관리자페이지] 1. 환경세팅

JEONG SUJIN·2024년 1월 8일
0

인사말

레퍼런스 블로그
1.https://kimvampa.tistory.com/304
2.https://congsong.tistory.com/24

이 두분 블로그를 보면서 저도 만들면서 너무 감사하게 많이 배웠습니다.
여기 블로그를 참고하면서 저도 만들고싶은 기능을 여러가지 기능을 만들려고 합니다..!
감사합니다. 🙇🏻‍♀️


환경설정

MVC패턴
스프링부트sts4사용
스프링부트버전 2.7.18
gradle
Thymeleaf
MySql
Properties
Mybatis

application.Properties

# db연결에 필요한 정보 log4jdbc 등
spring.datasource.hikari.driver-class-name=net.sf.log4jdbc.sql.jdbcapi.DriverSpy
spring.datasource.hikari.jdbc-url=jdbc:log4jdbc:mysql://localhost:3306/board

spring.datasource.hikari.username=아이디
spring.datasource.hikari.password=비밀번호
spring.datasource.hikari.connection-test-query=SELECT NOW() FROM dual

#SELECT 칼럼과 멤버 변수 매핑(바인딩)하기
mybatis.configuration.map-underscore-to-camel-case=true


build.gradle

plugins {
	id 'java'
	id 'org.springframework.boot' version '2.7.18'
	id 'io.spring.dependency-management' version '1.0.15.RELEASE'
}

group = 'com.various_functions'
version = '0.0.1-SNAPSHOT'

java {
	sourceCompatibility = '11'
}

configurations {
	compileOnly {
		extendsFrom annotationProcessor
	}
}

repositories {
	mavenCentral()
}

dependencies {
	implementation 'org.springframework.boot:spring-boot-starter-data-jdbc'
	implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
	implementation 'mysql:mysql-connector-java:8.0.33'
	implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'	
	implementation 'org.springframework.boot:spring-boot-starter-validation'
	implementation 'org.springframework.boot:spring-boot-starter-web'
	implementation 'org.mybatis.spring.boot:mybatis-spring-boot-starter:2.2.0'
	implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect' /* Thymeleaf Layout */
	implementation 'org.bgee.log4jdbc-log4j2:log4jdbc-log4j2-jdbc4.1:1.16'  /* Log4JDBC */
	implementation group: 'org.springframework.security', name: 'spring-security-crypto', version: '5.7.6'  /* spring-security-crypto */
	implementation 'com.google.code.gson:gson:2.9.0'
	 
	compileOnly 'org.projectlombok:lombok'
	//compile group: 'com.google.code.gson', name: 'gson', version: '2.8.2'

	developmentOnly 'org.springframework.boot:spring-boot-devtools'
	annotationProcessor 'org.springframework.boot:spring-boot-configuration-processor'
	annotationProcessor 'org.projectlombok:lombok'
	testImplementation 'org.springframework.boot:spring-boot-starter-test'
	//testImplementation 'org.springframework.security:spring-security-test'
}

tasks.named('test') {
	useJUnitPlatform()
}
profile
기록하기

0개의 댓글