-
Notifications
You must be signed in to change notification settings - Fork 1
54 lines (46 loc) · 1.46 KB
/
swagger.yml
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
50
51
52
53
54
name: Order-Deploy
on:
pull_request:
branches:
- deploy
types:
- closed
paths:
- "lottery/**"
- "order/**"
- "common/**"
jobs:
test:
runs-on: ubuntu-latest
steps:
# 스니펫을 불러온다.
- name: Download multiple files as an artifact
uses: actions/download-artifact@v3
with:
name: order-snippets
path: order/build/generated-snippets/
- name: Download multiple files as an artifact
uses: actions/download-artifact@v3
with:
name: lottery-snippets
path: lottery/build/generated-snippets/
- name: Verify files downloaded
run: |
echo "Download Files"
ls -la order/build/generated-snippets/
ls -la lottery/build/generated-snippets/
- name: Generate Swagger Document
run: |
./gradlew mergeApiSpecs
./gradlew openapi3
./gradlew customGenerateSwaggerUI
ls
# 스웨거를 업로드한다.
- name: Upload to S3
uses: jakejarvis/s3-sync-action@master
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_S3_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_S3_SECRET_ACCESS_KEY }}
AWS_REGION: 'ap-northeast-2' # 리전 정보
SOURCE_DIR: 'swagger-ui-watermelon' # 업로드할 파일들이 위치한 로컬 디렉토리
AWS_S3_BUCKET: 'watermelon-s3-bucket' # S3 버킷 이름