260703_01_FST: First Commit
This commit is contained in:
81
README.md
Normal file
81
README.md
Normal file
@@ -0,0 +1,81 @@
|
||||
# @kri/create-spring-app
|
||||
|
||||
KRI 표준 Spring Boot 프로젝트 생성 CLI입니다.
|
||||
|
||||
## 기본 구성
|
||||
|
||||
- Java 17
|
||||
- Spring Boot 3.5.7
|
||||
- Gradle Groovy DSL / Gradle Wrapper 8.14.3
|
||||
- `com.kri.common:starter:latest.release`
|
||||
- JPA + QueryDSL + JdbcTemplate 벌크 처리 예제
|
||||
- EmbeddedId 복합키 예제
|
||||
- MyBatis 선택 설치
|
||||
- MySQL 또는 MSSQL 선택
|
||||
- JWT/Security와 API Key는 공용 Starter 설정으로 활성화
|
||||
- Scheduler, 파일 저장소, 정적 리소스 설정 예제
|
||||
- Jenkinsfile 및 systemd 서비스 예제
|
||||
|
||||
## 개발
|
||||
|
||||
```powershell
|
||||
npm install
|
||||
npm run typecheck
|
||||
npm run build
|
||||
```
|
||||
|
||||
## 로컬 실행 테스트
|
||||
|
||||
```powershell
|
||||
node .\dist\cli.js sample-server --yes --skip-build
|
||||
```
|
||||
|
||||
전체 생성 및 Gradle 빌드:
|
||||
|
||||
```powershell
|
||||
node .\dist\cli.js sample-server --yes
|
||||
```
|
||||
|
||||
## 배포 후 사용
|
||||
|
||||
```powershell
|
||||
npx @kri/create-spring-app sample-server
|
||||
```
|
||||
|
||||
## 옵션
|
||||
|
||||
```text
|
||||
--base-package <package> 기본 패키지
|
||||
--description <text> 프로젝트 설명
|
||||
--port <number> 서버 포트 (기본 8080)
|
||||
--database mysql|mssql DB 종류 (기본 mysql)
|
||||
--mybatis MyBatis 예제 포함
|
||||
--repo-url <url> Gitea 저장소 URL
|
||||
--app-root <path> Ubuntu 배포 경로
|
||||
--service-name <name> systemd 서비스 이름
|
||||
--branch <name> 배포 브랜치 (기본 master)
|
||||
--agent-label <label> Jenkins Agent label (기본 ubuntu-build)
|
||||
--maven-credential-id <id> Jenkins Maven Credential ID
|
||||
--target-dir <path> 생성 경로
|
||||
--yes, -y 질문 없이 기본값 사용
|
||||
--skip-build Gradle build 생략
|
||||
--no-jenkins Jenkinsfile 생성 안 함
|
||||
--force 비어 있지 않은 대상 폴더 사용
|
||||
--help, -h 도움말
|
||||
```
|
||||
|
||||
## Gitea Maven 인증
|
||||
|
||||
개발자 PC의 `%USERPROFILE%\.gradle\gradle.properties`:
|
||||
|
||||
```properties
|
||||
giteaUser=사용자명
|
||||
giteaToken=Gitea토큰
|
||||
```
|
||||
|
||||
또는 환경변수:
|
||||
|
||||
```text
|
||||
GITEA_MAVEN_USER
|
||||
GITEA_MAVEN_TOKEN
|
||||
```
|
||||
Reference in New Issue
Block a user