ci: Gitea Actions 자동배포 워크플로우 구성 (#12) #14
49
.gitea/workflows/deploy.yml
Normal file
49
.gitea/workflows/deploy.yml
Normal file
@ -0,0 +1,49 @@
|
||||
name: Build and Deploy SNP Sync Batch
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
build-and-deploy:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: maven:3.9-eclipse-temurin-17
|
||||
steps:
|
||||
- name: Checkout
|
||||
run: |
|
||||
git clone --depth=1 --branch=${GITHUB_REF_NAME} \
|
||||
http://gitea:3000/${GITHUB_REPOSITORY}.git .
|
||||
|
||||
- name: Configure Maven settings
|
||||
run: |
|
||||
mkdir -p ~/.m2
|
||||
cat > ~/.m2/settings.xml << 'SETTINGS'
|
||||
<settings>
|
||||
<mirrors>
|
||||
<mirror>
|
||||
<id>nexus</id>
|
||||
<mirrorOf>*</mirrorOf>
|
||||
<url>https://nexus.gc-si.dev/repository/maven-public/</url>
|
||||
</mirror>
|
||||
</mirrors>
|
||||
<servers>
|
||||
<server>
|
||||
<id>nexus</id>
|
||||
<username>${{ secrets.NEXUS_USERNAME }}</username>
|
||||
<password>${{ secrets.NEXUS_PASSWORD }}</password>
|
||||
</server>
|
||||
</servers>
|
||||
</settings>
|
||||
SETTINGS
|
||||
|
||||
- name: Build
|
||||
run: mvn clean package -DskipTests -B
|
||||
|
||||
- name: Deploy
|
||||
run: |
|
||||
cp target/snp-sync-batch-*.jar /deploy/snp-sync-batch/app.jar
|
||||
date '+%Y-%m-%d %H:%M:%S' > /deploy/snp-sync-batch/.deploy-trigger
|
||||
echo "Deployed at $(cat /deploy/snp-sync-batch/.deploy-trigger)"
|
||||
ls -la /deploy/snp-sync-batch/
|
||||
@ -22,6 +22,7 @@
|
||||
- 스케줄 toggle API 메서드 불일치 수정: POST → PATCH (#6)
|
||||
|
||||
### 기타
|
||||
- Gitea Actions 자동배포 워크플로우 구성 (#12)
|
||||
- .gitignore에 logs/ 추가
|
||||
- application-dev.yml chunk-size, sub-chunk-size 설정 추가
|
||||
- Repository 배치 삽입 로그 주석처리
|
||||
|
||||
불러오는 중...
Reference in New Issue
Block a user