-
Notifications
You must be signed in to change notification settings - Fork 2
49 lines (44 loc) · 1.44 KB
/
CI.yml
File metadata and controls
49 lines (44 loc) · 1.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle
name: CI
on:
pull_request:
branches: [ "deploy" ]
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
steps:
# Redis 다운로드
- name: Setup Redis
uses: zhulik/redis-action@1.1.0
with:
redis version: 7.2
- uses: actions/checkout@v3
# java 다운로드
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
# .env 파일 복사
- name: Move .env.example to .env
run: mv .env.example .env
shell: bash
# gradlew에 실행권한 부여
- name: Grant execute permission for gradlew
run: chmod +x ./gradlew
shell: bash
# gradle 빌드 및 테스트 실행
- name: Build with Gradle
run: ./gradlew build -Dspring.profiles.active=test
shell: bash
# .env 파일 제거
- name: Move .env to .env.example
run: mv .env .env.example
shell: bash