project-auto-wizard 0.9.0 โ 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/package.json +1 -1
- package/payload/scripts/__pycache__/changelog_manager.cpython-314.pyc +0 -0
- package/payload/scripts/__pycache__/issue_helper.cpython-314.pyc +0 -0
- package/payload/scripts/__pycache__/version_manager.cpython-314.pyc +0 -0
- package/payload/scripts/changelog_manager.py +2 -2
- package/payload/scripts/version_manager.py +2 -2
- package/payload/version.yml.template +1 -1
- package/payload/workflows/common/secret-backup/PROJECT-COMMON-SECRET-FILE-UPLOAD.yaml +12 -12
- package/payload/workflows/flutter/PROJECT-FLUTTER-ANDROID-TEST-APK.yaml +1 -1
- package/payload/workflows/flutter/{PROJECT-FLUTTER-SUH-LAB-APP-BUILD-TRIGGER.yaml โ PROJECT-FLUTTER-APP-BUILD-TRIGGER.yaml} +38 -38
- package/payload/workflows/flutter/PROJECT-FLUTTER-IOS-TEST-TESTFLIGHT.yaml +1 -1
- package/payload/workflows/go/PROJECT-GO-PR-PREVIEW.yaml +40 -40
- package/payload/workflows/python/PROJECT-PYTHON-PR-PREVIEW.yaml +40 -40
- package/payload/workflows/spring/server-deploy/PROJECT-SPRING-PR-PREVIEW.yaml +39 -39
- package/src/cli/args.js +2 -2
- package/src/cli/help.js +1 -1
- package/src/core/copy/workflows.js +21 -9
- package/src/core/deploy-style.js +9 -1
- package/src/core/verify.js +2 -2
- package/src/ui/env-plan.js +14 -4
- package/src/ui/prompts.js +10 -4
|
@@ -19,9 +19,9 @@
|
|
|
19
19
|
# ===================================================================
|
|
20
20
|
#
|
|
21
21
|
# ๐ ์ฌ์ฉ๋ฒ:
|
|
22
|
-
#
|
|
23
|
-
#
|
|
24
|
-
#
|
|
22
|
+
# /wizard server build - Preview ๋น๋ ๋ฐ ๋ฐฐํฌ
|
|
23
|
+
# /wizard server destroy - Preview ํ๊ฒฝ ์ญ์
|
|
24
|
+
# /wizard server status - ํ์ฌ ์ํ ํ์ธ
|
|
25
25
|
#
|
|
26
26
|
# ๐ ๋ฆฌ์์ค ๋ค์ด๋ฐ:
|
|
27
27
|
# - ์ปจํ
์ด๋: {PROJECT_NAME}-pr-{๋ฒํธ}
|
|
@@ -64,7 +64,7 @@ env:
|
|
|
64
64
|
|
|
65
65
|
# Issue Helper ๋๊ธ ๋ง์ปค (ํ๋ก์ ํธ๋ณ ์์ ํ์)
|
|
66
66
|
# Issue ๋๊ธ์์ ๋ธ๋์น๋ช
์ ์ถ์ถํ ๋ ์ฌ์ฉ
|
|
67
|
-
ISSUE_HELPER_MARKER: '
|
|
67
|
+
ISSUE_HELPER_MARKER: '<!-- project-auto-wizard issue helper -->'
|
|
68
68
|
|
|
69
69
|
# Health Check ์ค์ (ํ๋ก์ ํธ๋ณ ์์ ํ์)
|
|
70
70
|
# - HEALTH_CHECK_PATH: HTTP Health Check ๊ฒฝ๋ก (๋น๊ฐ์ด๋ฉด HTTP ์ฒดํฌ ๊ฑด๋๋)
|
|
@@ -114,7 +114,7 @@ jobs:
|
|
|
114
114
|
is_custom_branch: ${{ steps.parse.outputs.is_custom_branch }}
|
|
115
115
|
steps:
|
|
116
116
|
- name: ๋๊ธ์ ๐ ๋ฆฌ์ก์
์ถ๊ฐ
|
|
117
|
-
if: contains(github.event.comment.body, '
|
|
117
|
+
if: contains(github.event.comment.body, '/wizard') && contains(github.event.comment.body, 'server')
|
|
118
118
|
uses: actions/github-script@v9
|
|
119
119
|
with:
|
|
120
120
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
@@ -142,8 +142,8 @@ jobs:
|
|
|
142
142
|
fi
|
|
143
143
|
|
|
144
144
|
# ๋ช
๋ น์ด ํ์ฑ (๋ธ๋์น ํ๋ผ๋ฏธํฐ ์ง์)
|
|
145
|
-
# ํ์:
|
|
146
|
-
if [[ "$COMMENT" =~
|
|
145
|
+
# ํ์: /wizard server <command> [๋ธ๋์น๋ช
]
|
|
146
|
+
if [[ "$COMMENT" =~ /wizard[[:space:]]+server[[:space:]]+build([[:space:]]+([^[:space:]]+))? ]]; then
|
|
147
147
|
echo "command=build" >> $GITHUB_OUTPUT
|
|
148
148
|
echo "is_valid=true" >> $GITHUB_OUTPUT
|
|
149
149
|
if [[ -n "${BASH_REMATCH[2]}" ]]; then
|
|
@@ -154,7 +154,7 @@ jobs:
|
|
|
154
154
|
echo "is_custom_branch=false" >> $GITHUB_OUTPUT
|
|
155
155
|
echo "โ
๋ช
๋ น์ด ๊ฐ์ง: build"
|
|
156
156
|
fi
|
|
157
|
-
elif [[ "$COMMENT" =~
|
|
157
|
+
elif [[ "$COMMENT" =~ /wizard[[:space:]]+server[[:space:]]+destroy([[:space:]]+([^[:space:]]+))? ]]; then
|
|
158
158
|
echo "command=destroy" >> $GITHUB_OUTPUT
|
|
159
159
|
echo "is_valid=true" >> $GITHUB_OUTPUT
|
|
160
160
|
if [[ -n "${BASH_REMATCH[2]}" ]]; then
|
|
@@ -165,7 +165,7 @@ jobs:
|
|
|
165
165
|
echo "is_custom_branch=false" >> $GITHUB_OUTPUT
|
|
166
166
|
echo "โ
๋ช
๋ น์ด ๊ฐ์ง: destroy"
|
|
167
167
|
fi
|
|
168
|
-
elif [[ "$COMMENT" =~
|
|
168
|
+
elif [[ "$COMMENT" =~ /wizard[[:space:]]+server[[:space:]]+status([[:space:]]+([^[:space:]]+))? ]]; then
|
|
169
169
|
echo "command=status" >> $GITHUB_OUTPUT
|
|
170
170
|
echo "is_valid=true" >> $GITHUB_OUTPUT
|
|
171
171
|
if [[ -n "${BASH_REMATCH[2]}" ]]; then
|
|
@@ -178,7 +178,7 @@ jobs:
|
|
|
178
178
|
fi
|
|
179
179
|
else
|
|
180
180
|
echo "is_valid=false" >> $GITHUB_OUTPUT
|
|
181
|
-
echo "โน๏ธ
|
|
181
|
+
echo "โน๏ธ /wizard server ๋ช
๋ น์ด๊ฐ ์๋"
|
|
182
182
|
fi
|
|
183
183
|
|
|
184
184
|
# -----------------------------------------------------------------
|
|
@@ -518,17 +518,17 @@ jobs:
|
|
|
518
518
|
'### ๐ ๋ช
๋ น์ด',
|
|
519
519
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
520
520
|
'|--------|------|',
|
|
521
|
-
'|
|
|
522
|
-
'|
|
|
523
|
-
'|
|
|
521
|
+
'| `/wizard server build` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |',
|
|
522
|
+
'| `/wizard server destroy` | Preview ํ๊ฒฝ ์ญ์ |',
|
|
523
|
+
'| `/wizard server status` | ํ์ฌ ์ํ ํ์ธ |',
|
|
524
524
|
'',
|
|
525
525
|
'<details>',
|
|
526
526
|
'<summary>๐ง ๊ณ ๊ธ ๋ช
๋ น์ด (๋ค๋ฅธ Issue/PR์์ ์ ์ด)</summary>',
|
|
527
527
|
'',
|
|
528
528
|
'```',
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
529
|
+
`/wizard server build ${branchName}`,
|
|
530
|
+
`/wizard server destroy ${branchName}`,
|
|
531
|
+
`/wizard server status ${branchName}`,
|
|
532
532
|
'```',
|
|
533
533
|
'</details>',
|
|
534
534
|
'',
|
|
@@ -593,7 +593,7 @@ jobs:
|
|
|
593
593
|
'',
|
|
594
594
|
'### ๐ก ๋ค์ ๋จ๊ณ',
|
|
595
595
|
'1. ์ ๋งํฌ์์ ๋น๋/๋ฐฐํฌ ๋ก๊ทธ๋ฅผ ํ์ธํ์ธ์',
|
|
596
|
-
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์:
|
|
596
|
+
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์: `/wizard server build`',
|
|
597
597
|
'',
|
|
598
598
|
'---',
|
|
599
599
|
'*๐ค ์ด ๋๊ธ์ PR Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -1114,17 +1114,17 @@ jobs:
|
|
|
1114
1114
|
'### ๐ ๋ช
๋ น์ด',
|
|
1115
1115
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
1116
1116
|
'|--------|------|',
|
|
1117
|
-
'|
|
|
1118
|
-
'|
|
|
1119
|
-
'|
|
|
1117
|
+
'| `/wizard server build` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |',
|
|
1118
|
+
'| `/wizard server destroy` | Preview ํ๊ฒฝ ์ญ์ |',
|
|
1119
|
+
'| `/wizard server status` | ํ์ฌ ์ํ ํ์ธ |',
|
|
1120
1120
|
'',
|
|
1121
1121
|
'<details>',
|
|
1122
1122
|
'<summary>๐ง ๊ณ ๊ธ ๋ช
๋ น์ด (๋ค๋ฅธ Issue/PR์์ ์ ์ด)</summary>',
|
|
1123
1123
|
'',
|
|
1124
1124
|
'```',
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1125
|
+
`/wizard server build ${branchName}`,
|
|
1126
|
+
`/wizard server destroy ${branchName}`,
|
|
1127
|
+
`/wizard server status ${branchName}`,
|
|
1128
1128
|
'```',
|
|
1129
1129
|
'</details>',
|
|
1130
1130
|
'',
|
|
@@ -1187,7 +1187,7 @@ jobs:
|
|
|
1187
1187
|
'',
|
|
1188
1188
|
'### ๐ก ๋ค์ ๋จ๊ณ',
|
|
1189
1189
|
'1. ์ ๋งํฌ์์ ๋น๋/๋ฐฐํฌ ๋ก๊ทธ๋ฅผ ํ์ธํ์ธ์',
|
|
1190
|
-
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์:
|
|
1190
|
+
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์: `/wizard server build`',
|
|
1191
1191
|
'',
|
|
1192
1192
|
'---',
|
|
1193
1193
|
'*๐ค ์ด ๋๊ธ์ Issue Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -1218,7 +1218,7 @@ jobs:
|
|
|
1218
1218
|
if: |
|
|
1219
1219
|
(github.event_name == 'pull_request' && github.event.action == 'closed') ||
|
|
1220
1220
|
(github.event_name == 'issues' && github.event.action == 'closed') ||
|
|
1221
|
-
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '
|
|
1221
|
+
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '/wizard') && contains(github.event.comment.body, 'server destroy'))
|
|
1222
1222
|
runs-on: ubuntu-latest
|
|
1223
1223
|
steps:
|
|
1224
1224
|
- name: PR/Issue ๋ฒํธ ๊ฐ์ ธ์ค๊ธฐ
|
|
@@ -1301,7 +1301,7 @@ jobs:
|
|
|
1301
1301
|
`| **์ปจํ
์ด๋** | \`${projectName}-pr-${number}\` |`,
|
|
1302
1302
|
'| **์ํ** | ์ญ์ ๋จ |',
|
|
1303
1303
|
'',
|
|
1304
|
-
'๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด:
|
|
1304
|
+
'๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด: `/wizard server build`',
|
|
1305
1305
|
'',
|
|
1306
1306
|
'---',
|
|
1307
1307
|
'*๐ค ์ด ๋๊ธ์ PR/Issue Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -1400,8 +1400,8 @@ jobs:
|
|
|
1400
1400
|
'### ๐ ๋ช
๋ น์ด',
|
|
1401
1401
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
1402
1402
|
'|--------|------|',
|
|
1403
|
-
'|
|
|
1404
|
-
'|
|
|
1403
|
+
'| `/wizard server build` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |',
|
|
1404
|
+
'| `/wizard server destroy` | Preview ํ๊ฒฝ ์ญ์ |',
|
|
1405
1405
|
'',
|
|
1406
1406
|
'---',
|
|
1407
1407
|
`*๐ค ์ด ๋๊ธ์ ${contextType} Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*`
|
|
@@ -1415,7 +1415,7 @@ jobs:
|
|
|
1415
1415
|
`| **์ปจํ
์ด๋** | \`${projectName}-pr-${number}\` |`,
|
|
1416
1416
|
'| **์ํ** | ๐ด Not Found |',
|
|
1417
1417
|
'',
|
|
1418
|
-
'๋ฐฐํฌํ๋ ค๋ฉด:
|
|
1418
|
+
'๋ฐฐํฌํ๋ ค๋ฉด: `/wizard server build`',
|
|
1419
1419
|
'',
|
|
1420
1420
|
'---',
|
|
1421
1421
|
`*๐ค ์ด ๋๊ธ์ ${contextType} Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*`
|
|
@@ -1849,17 +1849,17 @@ jobs:
|
|
|
1849
1849
|
'### ๐ ๋ช
๋ น์ด',
|
|
1850
1850
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
1851
1851
|
'|--------|------|',
|
|
1852
|
-
'|
|
|
1853
|
-
'|
|
|
1854
|
-
'|
|
|
1852
|
+
'| `/wizard server build` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |',
|
|
1853
|
+
'| `/wizard server destroy` | Preview ํ๊ฒฝ ์ญ์ |',
|
|
1854
|
+
'| `/wizard server status` | ํ์ฌ ์ํ ํ์ธ |',
|
|
1855
1855
|
'',
|
|
1856
1856
|
'<details>',
|
|
1857
1857
|
'<summary>๐ง ๊ณ ๊ธ ๋ช
๋ น์ด (๋ค๋ฅธ Issue/PR์์ ์ ์ด)</summary>',
|
|
1858
1858
|
'',
|
|
1859
1859
|
'```',
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1860
|
+
`/wizard server build ${branchName}`,
|
|
1861
|
+
`/wizard server destroy ${branchName}`,
|
|
1862
|
+
`/wizard server status ${branchName}`,
|
|
1863
1863
|
'```',
|
|
1864
1864
|
'</details>',
|
|
1865
1865
|
'',
|
|
@@ -1920,7 +1920,7 @@ jobs:
|
|
|
1920
1920
|
'',
|
|
1921
1921
|
'### ๐ก ๋ค์ ๋จ๊ณ',
|
|
1922
1922
|
'1. ์ ๋งํฌ์์ ๋น๋/๋ฐฐํฌ ๋ก๊ทธ๋ฅผ ํ์ธํ์ธ์',
|
|
1923
|
-
`2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์:
|
|
1923
|
+
`2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์: \`/wizard server build ${branchName}\``,
|
|
1924
1924
|
'',
|
|
1925
1925
|
'---',
|
|
1926
1926
|
'*๐ค ์ด ๋๊ธ์ Custom Branch Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -2050,7 +2050,7 @@ jobs:
|
|
|
2050
2050
|
`| **์ปจํ
์ด๋** | \`${containerName}\` |`,
|
|
2051
2051
|
'| **์ํ** | ์ญ์ ๋จ |',
|
|
2052
2052
|
'',
|
|
2053
|
-
`๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด:
|
|
2053
|
+
`๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด: \`/wizard server build ${branchName}\``,
|
|
2054
2054
|
'',
|
|
2055
2055
|
'---',
|
|
2056
2056
|
'*๐ค ์ด ๋๊ธ์ Custom Branch Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -2161,8 +2161,8 @@ jobs:
|
|
|
2161
2161
|
'### ๐ ๋ช
๋ น์ด',
|
|
2162
2162
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
2163
2163
|
'|--------|------|',
|
|
2164
|
-
`|
|
|
2165
|
-
`|
|
|
2164
|
+
`| \`/wizard server build ${branchName}\` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |`,
|
|
2165
|
+
`| \`/wizard server destroy ${branchName}\` | Preview ํ๊ฒฝ ์ญ์ |`,
|
|
2166
2166
|
'',
|
|
2167
2167
|
'---',
|
|
2168
2168
|
'*๐ค ์ด ๋๊ธ์ Custom Branch Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -2177,7 +2177,7 @@ jobs:
|
|
|
2177
2177
|
`| **์ปจํ
์ด๋** | \`${containerName}\` |`,
|
|
2178
2178
|
'| **์ํ** | ๐ด Not Found |',
|
|
2179
2179
|
'',
|
|
2180
|
-
`๋ฐฐํฌํ๋ ค๋ฉด:
|
|
2180
|
+
`๋ฐฐํฌํ๋ ค๋ฉด: \`/wizard server build ${branchName}\``,
|
|
2181
2181
|
'',
|
|
2182
2182
|
'---',
|
|
2183
2183
|
'*๐ค ์ด ๋๊ธ์ Custom Branch Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -15,9 +15,9 @@
|
|
|
15
15
|
# ===================================================================
|
|
16
16
|
#
|
|
17
17
|
# ๐ ์ฌ์ฉ๋ฒ:
|
|
18
|
-
#
|
|
19
|
-
#
|
|
20
|
-
#
|
|
18
|
+
# /wizard server build - PR/Issue ๋น๋ ๋ฐ ๋ฐฐํฌ
|
|
19
|
+
# /wizard server destroy - Preview ํ๊ฒฝ ์ญ์
|
|
20
|
+
# /wizard server status - ํ์ฌ ์ํ ํ์ธ
|
|
21
21
|
#
|
|
22
22
|
# ๐ ๋ฆฌ์์ค ๋ค์ด๋ฐ ๊ท์น:
|
|
23
23
|
# - ์ปจํ
์ด๋: {PROJECT_NAME}-pr-{PR๋ฒํธ}
|
|
@@ -65,7 +65,7 @@ env:
|
|
|
65
65
|
|
|
66
66
|
# Issue Helper ๋๊ธ ๋ง์ปค (ํ๋ก์ ํธ๋ณ ์์ ํ์)
|
|
67
67
|
# Issue ๋๊ธ์์ ๋ธ๋์น๋ช
์ ์ถ์ถํ ๋ ์ฌ์ฉ
|
|
68
|
-
ISSUE_HELPER_MARKER: '
|
|
68
|
+
ISSUE_HELPER_MARKER: '<!-- project-auto-wizard issue helper -->'
|
|
69
69
|
|
|
70
70
|
# Health Check ์ค์ (ํ๋ก์ ํธ๋ณ ์์ ํ์)
|
|
71
71
|
# - HEALTH_CHECK_PATH: HTTP Health Check ๊ฒฝ๋ก (๋น๊ฐ์ด๋ฉด HTTP ์ฒดํฌ ๊ฑด๋๋)
|
|
@@ -115,7 +115,7 @@ jobs:
|
|
|
115
115
|
is_custom_branch: ${{ steps.parse.outputs.is_custom_branch }}
|
|
116
116
|
steps:
|
|
117
117
|
- name: ๋๊ธ์ ๐ ๋ฆฌ์ก์
์ถ๊ฐ
|
|
118
|
-
if: contains(github.event.comment.body, '
|
|
118
|
+
if: contains(github.event.comment.body, '/wizard') && contains(github.event.comment.body, 'server')
|
|
119
119
|
uses: actions/github-script@v9
|
|
120
120
|
with:
|
|
121
121
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
@@ -143,8 +143,8 @@ jobs:
|
|
|
143
143
|
fi
|
|
144
144
|
|
|
145
145
|
# ๋ช
๋ น์ด ํ์ฑ (๋ธ๋์น ํ๋ผ๋ฏธํฐ ์ง์)
|
|
146
|
-
# ํ์:
|
|
147
|
-
if [[ "$COMMENT" =~
|
|
146
|
+
# ํ์: /wizard server <command> [๋ธ๋์น๋ช
]
|
|
147
|
+
if [[ "$COMMENT" =~ /wizard[[:space:]]+server[[:space:]]+build([[:space:]]+([^[:space:]]+))? ]]; then
|
|
148
148
|
echo "command=build" >> $GITHUB_OUTPUT
|
|
149
149
|
echo "is_valid=true" >> $GITHUB_OUTPUT
|
|
150
150
|
if [[ -n "${BASH_REMATCH[2]}" ]]; then
|
|
@@ -155,7 +155,7 @@ jobs:
|
|
|
155
155
|
echo "is_custom_branch=false" >> $GITHUB_OUTPUT
|
|
156
156
|
echo "โ
๋ช
๋ น์ด ๊ฐ์ง: build"
|
|
157
157
|
fi
|
|
158
|
-
elif [[ "$COMMENT" =~
|
|
158
|
+
elif [[ "$COMMENT" =~ /wizard[[:space:]]+server[[:space:]]+destroy([[:space:]]+([^[:space:]]+))? ]]; then
|
|
159
159
|
echo "command=destroy" >> $GITHUB_OUTPUT
|
|
160
160
|
echo "is_valid=true" >> $GITHUB_OUTPUT
|
|
161
161
|
if [[ -n "${BASH_REMATCH[2]}" ]]; then
|
|
@@ -166,7 +166,7 @@ jobs:
|
|
|
166
166
|
echo "is_custom_branch=false" >> $GITHUB_OUTPUT
|
|
167
167
|
echo "โ
๋ช
๋ น์ด ๊ฐ์ง: destroy"
|
|
168
168
|
fi
|
|
169
|
-
elif [[ "$COMMENT" =~
|
|
169
|
+
elif [[ "$COMMENT" =~ /wizard[[:space:]]+server[[:space:]]+status([[:space:]]+([^[:space:]]+))? ]]; then
|
|
170
170
|
echo "command=status" >> $GITHUB_OUTPUT
|
|
171
171
|
echo "is_valid=true" >> $GITHUB_OUTPUT
|
|
172
172
|
if [[ -n "${BASH_REMATCH[2]}" ]]; then
|
|
@@ -179,7 +179,7 @@ jobs:
|
|
|
179
179
|
fi
|
|
180
180
|
else
|
|
181
181
|
echo "is_valid=false" >> $GITHUB_OUTPUT
|
|
182
|
-
echo "โน๏ธ
|
|
182
|
+
echo "โน๏ธ /wizard server ๋ช
๋ น์ด๊ฐ ์๋"
|
|
183
183
|
fi
|
|
184
184
|
|
|
185
185
|
# -----------------------------------------------------------------
|
|
@@ -292,13 +292,13 @@ jobs:
|
|
|
292
292
|
# env:
|
|
293
293
|
# VERTEX_SA_KEY: ${{ secrets.VERTEX_SA_KEY }}
|
|
294
294
|
# run: |
|
|
295
|
-
# echo "$VERTEX_SA_KEY" | sed 's/\\n/\n/g' >
|
|
295
|
+
# echo "$VERTEX_SA_KEY" | sed 's/\\n/\n/g' > ./<๋ชจ๋๋ช
>/src/main/resources/vertex-ai-key.json
|
|
296
296
|
|
|
297
297
|
# - name: "[์ ํ] Firebase Admin SDK ์์ฑ"
|
|
298
298
|
# env:
|
|
299
299
|
# FIREBASE_KEY_JSON: ${{ secrets.FIREBASE_KEY_JSON }}
|
|
300
300
|
# run: |
|
|
301
|
-
# echo "$FIREBASE_KEY_JSON" | sed 's/\\n/\n/g' >
|
|
301
|
+
# echo "$FIREBASE_KEY_JSON" | sed 's/\\n/\n/g' > ./<๋ชจ๋๋ช
>/src/main/resources/firebase-admin-sdk.json
|
|
302
302
|
|
|
303
303
|
# =================================================================
|
|
304
304
|
# โ ๏ธ [์์ญ 2 ๋] ํ๋ก์ ํธ๋ณ Secret ํ์ผ ์์ฑ ๋
|
|
@@ -606,17 +606,17 @@ jobs:
|
|
|
606
606
|
'### ๐ ๋ช
๋ น์ด',
|
|
607
607
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
608
608
|
'|--------|------|',
|
|
609
|
-
'|
|
|
610
|
-
'|
|
|
611
|
-
'|
|
|
609
|
+
'| `/wizard server build` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |',
|
|
610
|
+
'| `/wizard server destroy` | Preview ํ๊ฒฝ ์ญ์ |',
|
|
611
|
+
'| `/wizard server status` | ํ์ฌ ์ํ ํ์ธ |',
|
|
612
612
|
'',
|
|
613
613
|
'<details>',
|
|
614
614
|
'<summary>๐ง ๊ณ ๊ธ ๋ช
๋ น์ด (๋ค๋ฅธ Issue/PR์์ ์ ์ด)</summary>',
|
|
615
615
|
'',
|
|
616
616
|
'```',
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
617
|
+
`/wizard server build ${branchName}`,
|
|
618
|
+
`/wizard server destroy ${branchName}`,
|
|
619
|
+
`/wizard server status ${branchName}`,
|
|
620
620
|
'```',
|
|
621
621
|
'</details>',
|
|
622
622
|
'',
|
|
@@ -693,7 +693,7 @@ jobs:
|
|
|
693
693
|
'',
|
|
694
694
|
'### ๐ก ๋ค์ ๋จ๊ณ',
|
|
695
695
|
'1. ์ ๋งํฌ์์ ๋น๋/๋ฐฐํฌ ๋ก๊ทธ๋ฅผ ํ์ธํ์ธ์',
|
|
696
|
-
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์:
|
|
696
|
+
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์: `/wizard server build`',
|
|
697
697
|
'',
|
|
698
698
|
'---',
|
|
699
699
|
'*๐ค ์ด ๋๊ธ์ PR Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -1278,17 +1278,17 @@ jobs:
|
|
|
1278
1278
|
'### ๐ ๋ช
๋ น์ด',
|
|
1279
1279
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
1280
1280
|
'|--------|------|',
|
|
1281
|
-
'|
|
|
1282
|
-
'|
|
|
1283
|
-
'|
|
|
1281
|
+
'| `/wizard server build` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |',
|
|
1282
|
+
'| `/wizard server destroy` | Preview ํ๊ฒฝ ์ญ์ |',
|
|
1283
|
+
'| `/wizard server status` | ํ์ฌ ์ํ ํ์ธ |',
|
|
1284
1284
|
'',
|
|
1285
1285
|
'<details>',
|
|
1286
1286
|
'<summary>๐ง ๊ณ ๊ธ ๋ช
๋ น์ด (๋ค๋ฅธ Issue/PR์์ ์ ์ด)</summary>',
|
|
1287
1287
|
'',
|
|
1288
1288
|
'```',
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1289
|
+
`/wizard server build ${branchName}`,
|
|
1290
|
+
`/wizard server destroy ${branchName}`,
|
|
1291
|
+
`/wizard server status ${branchName}`,
|
|
1292
1292
|
'```',
|
|
1293
1293
|
'</details>',
|
|
1294
1294
|
'',
|
|
@@ -1362,7 +1362,7 @@ jobs:
|
|
|
1362
1362
|
'',
|
|
1363
1363
|
'### ๐ก ๋ค์ ๋จ๊ณ',
|
|
1364
1364
|
'1. ์ ๋งํฌ์์ ๋น๋/๋ฐฐํฌ ๋ก๊ทธ๋ฅผ ํ์ธํ์ธ์',
|
|
1365
|
-
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์:
|
|
1365
|
+
'2. ๋ฌธ์ ๋ฅผ ์์ ํ ํ ๋ค์ ์๋ํ์ธ์: `/wizard server build`',
|
|
1366
1366
|
'',
|
|
1367
1367
|
'---',
|
|
1368
1368
|
'*๐ค ์ด ๋๊ธ์ Issue Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -1393,7 +1393,7 @@ jobs:
|
|
|
1393
1393
|
if: |
|
|
1394
1394
|
(github.event_name == 'pull_request' && github.event.action == 'closed') ||
|
|
1395
1395
|
(github.event_name == 'issues' && github.event.action == 'closed') ||
|
|
1396
|
-
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '
|
|
1396
|
+
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '/wizard') && contains(github.event.comment.body, 'server destroy'))
|
|
1397
1397
|
runs-on: ubuntu-latest
|
|
1398
1398
|
steps:
|
|
1399
1399
|
- name: PR/Issue ๋ฒํธ ๊ฐ์ ธ์ค๊ธฐ
|
|
@@ -1474,7 +1474,7 @@ jobs:
|
|
|
1474
1474
|
`| **์ปจํ
์ด๋** | \`${projectName}-pr-${number}\` |`,
|
|
1475
1475
|
'| **์ํ** | ์ญ์ ๋จ |',
|
|
1476
1476
|
'',
|
|
1477
|
-
'๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด:
|
|
1477
|
+
'๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด: `/wizard server build`',
|
|
1478
1478
|
'',
|
|
1479
1479
|
'---',
|
|
1480
1480
|
'*๐ค ์ด ๋๊ธ์ PR/Issue Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -1573,8 +1573,8 @@ jobs:
|
|
|
1573
1573
|
'### ๐ ๋ช
๋ น์ด',
|
|
1574
1574
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
1575
1575
|
'|--------|------|',
|
|
1576
|
-
'|
|
|
1577
|
-
'|
|
|
1576
|
+
'| `/wizard server build` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |',
|
|
1577
|
+
'| `/wizard server destroy` | Preview ํ๊ฒฝ ์ญ์ |',
|
|
1578
1578
|
'',
|
|
1579
1579
|
'---',
|
|
1580
1580
|
`*๐ค ์ด ๋๊ธ์ ${contextType} Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*`
|
|
@@ -1588,7 +1588,7 @@ jobs:
|
|
|
1588
1588
|
`| **์ปจํ
์ด๋** | \`${projectName}-pr-${number}\` |`,
|
|
1589
1589
|
'| **์ํ** | ๐ด Not Found |',
|
|
1590
1590
|
'',
|
|
1591
|
-
'๋ฐฐํฌํ๋ ค๋ฉด:
|
|
1591
|
+
'๋ฐฐํฌํ๋ ค๋ฉด: `/wizard server build`',
|
|
1592
1592
|
'',
|
|
1593
1593
|
'---',
|
|
1594
1594
|
`*๐ค ์ด ๋๊ธ์ ${contextType} Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*`
|
|
@@ -1605,7 +1605,7 @@ jobs:
|
|
|
1605
1605
|
# ============================================================
|
|
1606
1606
|
# Custom Branch Preview Jobs
|
|
1607
1607
|
# ํน์ ๋ธ๋์น๋ฅผ ์ง์ ํ์ฌ ๋น๋/์ญ์ /์ํ ํ์ธํ๋ ๊ธฐ๋ฅ
|
|
1608
|
-
# ๋ช
๋ น์ด:
|
|
1608
|
+
# ๋ช
๋ น์ด: /wizard server build <๋ธ๋์น๋ช
>
|
|
1609
1609
|
# ============================================================
|
|
1610
1610
|
|
|
1611
1611
|
build-preview-custom-branch:
|
|
@@ -1984,9 +1984,9 @@ jobs:
|
|
|
1984
1984
|
'### ๐ ๋ช
๋ น์ด',
|
|
1985
1985
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
1986
1986
|
'|--------|------|',
|
|
1987
|
-
`|
|
|
1988
|
-
`|
|
|
1989
|
-
`|
|
|
1987
|
+
`| \`/wizard server build ${branchName}\` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |`,
|
|
1988
|
+
`| \`/wizard server destroy ${branchName}\` | Preview ํ๊ฒฝ ์ญ์ |`,
|
|
1989
|
+
`| \`/wizard server status ${branchName}\` | ํ์ฌ ์ํ ํ์ธ |`,
|
|
1990
1990
|
'',
|
|
1991
1991
|
'---',
|
|
1992
1992
|
'*๐ค ์ด ๋๊ธ์ Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -2154,7 +2154,7 @@ jobs:
|
|
|
2154
2154
|
`| **๋ธ๋์น** | \`${branchName}\` |`,
|
|
2155
2155
|
`| **์ปจํ
์ด๋** | \`${containerName}\` |`,
|
|
2156
2156
|
'',
|
|
2157
|
-
`๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด:
|
|
2157
|
+
`๋ค์ ๋ฐฐํฌํ๋ ค๋ฉด: \`/wizard server build ${branchName}\``,
|
|
2158
2158
|
'',
|
|
2159
2159
|
'---',
|
|
2160
2160
|
'*๐ค ์ด ๋๊ธ์ Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -2247,8 +2247,8 @@ jobs:
|
|
|
2247
2247
|
'### ๐ ๋ช
๋ น์ด',
|
|
2248
2248
|
'| ๋ช
๋ น์ด | ์ค๋ช
|',
|
|
2249
2249
|
'|--------|------|',
|
|
2250
|
-
`|
|
|
2251
|
-
`|
|
|
2250
|
+
`| \`/wizard server build ${branchName}\` | ์ต์ ์ปค๋ฐ์ผ๋ก ์ฌ๋ฐฐํฌ |`,
|
|
2251
|
+
`| \`/wizard server destroy ${branchName}\` | Preview ํ๊ฒฝ ์ญ์ |`,
|
|
2252
2252
|
'',
|
|
2253
2253
|
'---',
|
|
2254
2254
|
'*๐ค ์ด ๋๊ธ์ Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
|
@@ -2263,7 +2263,7 @@ jobs:
|
|
|
2263
2263
|
`| **์ปจํ
์ด๋** | \`${containerName}\` |`,
|
|
2264
2264
|
'| **์ํ** | ๐ด Not Found |',
|
|
2265
2265
|
'',
|
|
2266
|
-
`๋ฐฐํฌํ๋ ค๋ฉด:
|
|
2266
|
+
`๋ฐฐํฌํ๋ ค๋ฉด: \`/wizard server build ${branchName}\``,
|
|
2267
2267
|
'',
|
|
2268
2268
|
'---',
|
|
2269
2269
|
'*๐ค ์ด ๋๊ธ์ Preview ์์คํ
์ ์ํด ์๋ ์์ฑ๋์์ต๋๋ค.*'
|
package/src/cli/args.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// CLI ์ธ์ ํ์ฑ (.sh top-level while-case ๋ฑ๊ฐ) โ template_integrator.sh 842~920.
|
|
2
2
|
import { VALID_TYPES, VALID_MODES } from "../context.js";
|
|
3
|
-
import { DEPLOY_STYLES, isDeployStyle } from "../core/deploy-style.js";
|
|
3
|
+
import { DEPLOY_STYLES, isDeployStyle, NO_DEPLOY_STYLE } from "../core/deploy-style.js";
|
|
4
4
|
|
|
5
5
|
// argv(process.argv.slice(2)) โ ํ์ฑ ๊ฒฐ๊ณผ. ์ค๋ฅ ์ throw(ํธ์ถ๋ถ์์ exit 1).
|
|
6
6
|
export function parseArgs(argv) {
|
|
@@ -80,7 +80,7 @@ export function parseArgs(argv) {
|
|
|
80
80
|
case "--deploy-style": {
|
|
81
81
|
const v = args.shift();
|
|
82
82
|
if (!isDeployStyle(v)) {
|
|
83
|
-
throw new CliError(`--deploy-style ๊ฐ์ด ์ฌ๋ฐ๋ฅด์ง ์์ต๋๋ค: ${v ?? "(์์)"} (${DEPLOY_STYLES.map((s) => s.value).join(" | ")})`);
|
|
83
|
+
throw new CliError(`--deploy-style ๊ฐ์ด ์ฌ๋ฐ๋ฅด์ง ์์ต๋๋ค: ${v ?? "(์์)"} (${[...DEPLOY_STYLES.map((s) => s.value), NO_DEPLOY_STYLE].join(" | ")})`);
|
|
84
84
|
}
|
|
85
85
|
result.deployStyle = v; break;
|
|
86
86
|
}
|
package/src/cli/help.js
CHANGED
|
@@ -16,7 +16,7 @@ export const HELP_TEXT = `project-auto-wizard โ One command DevOps: GitHub-nat
|
|
|
16
16
|
--paths "t=p,..." ํ์
๋ณ ํ๋ก์ ํธ ๊ฒฝ๋ก (๋ชจ๋
ธ๋ ํฌ). ์: flutter=app,react=client
|
|
17
17
|
--main-branch B ๋ฆด๋ฆฌ์ค ๋ธ๋์น (๊ธฐ๋ณธ: ๊ฐ์ง๋ default branch)
|
|
18
18
|
--develop-branch B ๊ฐ๋ฐ ๋ธ๋์น (๊ธฐ๋ณธ: develop). ๋ฆด๋ฆฌ์ค ๋ธ๋์น์ ๊ฐ์ผ๋ฉด trunk-based ๋ชจ๋
|
|
19
|
-
--deploy-style STYLE ์๋ฒ ๋ฐฐํฌ ๋ฐฉ์: simple | nginx | traefik (๊ธฐ๋ณธ: simple)
|
|
19
|
+
--deploy-style STYLE ์๋ฒ ๋ฐฐํฌ ๋ฐฉ์: simple | nginx | traefik | none (๊ธฐ๋ณธ: simple)
|
|
20
20
|
--nexus / --no-nexus ๋ผ์ด๋ธ๋ฌ๋ฆฌ publish ์ํฌํ๋ก์ฐ ํฌํจ/์ ์ธ (Nexus + GitHub Packages)
|
|
21
21
|
--secret-backup / --no-secret-backup Secret ๋ฐฑ์
์ํฌํ๋ก์ฐ ํฌํจ/์ ์ธ
|
|
22
22
|
--semver-auto / --no-semver-auto ์ปค๋ฐ ํ์
๊ธฐ๋ฐ ์๋ major/minor/patch ์น๊ฒฉ (๊ธฐ๋ณธ: ์ฌ์ฉํจ)
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// ๋ํํ 3์ง์ (๊ธฐ์กด ํ์ผ ์ถฉ๋)์ copyWorkflowsInteractive(async)๊ฐ ๊ฒฐ์ Map์ ๋ง๋ค์ด
|
|
4
4
|
// ๋๊ธฐ ์์ง(copyWorkflows)์ hooks.decisions๋ก ์ ๋ฌํ๋ค โ ๊ธฐ์กด ์๊ทธ๋์ฒยทforce ๋์ ๋ฌด๋ณ๊ฒฝ.
|
|
5
5
|
import { join, basename } from "node:path";
|
|
6
|
-
import { deployFilter, isDeployWorkflow, activateDeployTrigger, DEFAULT_DEPLOY_STYLE } from "../deploy-style.js";
|
|
6
|
+
import { deployFilter, isDeployWorkflow, activateDeployTrigger, DEFAULT_DEPLOY_STYLE, NO_DEPLOY_STYLE } from "../deploy-style.js";
|
|
7
7
|
import { existsSync, readFileSync, writeFileSync, renameSync } from "node:fs";
|
|
8
8
|
import { PATHS, PAYLOAD } from "../paths.js";
|
|
9
9
|
import { exists, writeText, listYamlFiles } from "../fsutil.js";
|
|
@@ -296,9 +296,13 @@ export function surveyWorkflows(context, payloadRoot, targetRoot = ".") {
|
|
|
296
296
|
for (const type of types) {
|
|
297
297
|
const envOpts = { type, projectPath: paths.get(type) || ".", repoName, resolvers };
|
|
298
298
|
const typeDir = join(projectTypesDir, type);
|
|
299
|
-
if (exists(typeDir))
|
|
299
|
+
if (exists(typeDir)) {
|
|
300
|
+
collect(typeDir, envOpts, type, () => false, deployStyle === NO_DEPLOY_STYLE ? keepDeploy : null);
|
|
301
|
+
}
|
|
300
302
|
const serverDeployDir = join(typeDir, "server-deploy");
|
|
301
|
-
if (exists(serverDeployDir) && !includeNexus
|
|
303
|
+
if (exists(serverDeployDir) && !includeNexus && deployStyle !== NO_DEPLOY_STYLE) {
|
|
304
|
+
collect(serverDeployDir, envOpts, type, () => false, keepDeploy);
|
|
305
|
+
}
|
|
302
306
|
}
|
|
303
307
|
return { conflicts, removed };
|
|
304
308
|
}
|
|
@@ -333,17 +337,20 @@ function copyWorkflowsForType(type, projectTypesDir, workflowsDir, ctx, counters
|
|
|
333
337
|
// ์นํ์ ๋ค์ ๊ฑธ๋ฉด ์ฌ์ฉ์ ์์ ๋ณธ์ ๋ฎ์ด์ฐ๊ฒ ๋๋ค.
|
|
334
338
|
const untouched = [];
|
|
335
339
|
|
|
336
|
-
// ํ์
๋ณ ์ํฌํ๋ก์ฐ (์งํ์)
|
|
340
|
+
// ํ์
๋ณ ์ํฌํ๋ก์ฐ (์งํ์). go/python์ฒ๋ผ CD ์ํฌํ๋ก์ฐ๊ฐ server-deploy ์์ด ํ์
๋ฃจํธ์
|
|
341
|
+
// ๋ฐ๋ก ์๋ ํ์
๋ ์๋ค โ "๋ฐฐํฌ ์ ํจ"์ผ ๋๋ ํ์
๋ฃจํธ์์๋ CD ํ์ผ(SIMPLE-CICD ๋ฑ)์
|
|
342
|
+
// ๊ฑธ๋ฌ์ผ ํ๋ค. simple/nginx/traefik์ ์ค๋๊ณผ ๋์ผํ๊ฒ ํํฐ ์์ด ์ ๋ถ ๋ณต์ฌํ๋ค.
|
|
337
343
|
if (exists(typeDir)) {
|
|
338
|
-
const
|
|
344
|
+
const typeRootFilter = deployStyle === NO_DEPLOY_STYLE ? keepDeploy : undefined;
|
|
345
|
+
const c = processDir(typeDir, workflowsDir, envOpts, dirCtx, counters, typeRootFilter);
|
|
339
346
|
untouched.push(...c.unchanged, ...c.localOnly);
|
|
340
347
|
}
|
|
341
348
|
|
|
342
349
|
// server-deploy
|
|
343
350
|
const serverDeployDir = join(typeDir, "server-deploy");
|
|
344
351
|
if (exists(serverDeployDir)) {
|
|
345
|
-
if (includeNexus) {
|
|
346
|
-
// Nexus ํ๋ก์ ํธ โ ํด๋์งธ ์ ์ธ (๋ณต์ฌ ์ ํจ)
|
|
352
|
+
if (includeNexus || deployStyle === NO_DEPLOY_STYLE) {
|
|
353
|
+
// Nexus ํ๋ก์ ํธ ๋๋ "๋ฐฐํฌ ์ ํจ" โ ํด๋์งธ ์ ์ธ (๋ณต์ฌ ์ ํจ)
|
|
347
354
|
} else {
|
|
348
355
|
const c = processDir(serverDeployDir, workflowsDir, envOpts, dirCtx, counters, keepDeploy);
|
|
349
356
|
untouched.push(...c.unchanged, ...c.localOnly);
|
|
@@ -363,9 +370,11 @@ function copyWorkflowsForType(type, projectTypesDir, workflowsDir, ctx, counters
|
|
|
363
370
|
// env ์นํ โ ์ด ํ์
์ ์๋ณธ ๋๋ ํ ๋ฆฌ๋ค์์ ๋ณต์ฌ๋ผ ์กด์ฌํ๊ณ , ์๋์ง ์๊ธฐ๋ก ํ ๊ฒ์ด ์๋ ํ์ผ๋ง
|
|
364
371
|
for (const srcDir of [typeDir, serverDeployDir, nexusDir]) {
|
|
365
372
|
if (!exists(srcDir)) continue;
|
|
373
|
+
if (srcDir === serverDeployDir && (includeNexus || deployStyle === NO_DEPLOY_STYLE)) continue; // ํด๋์งธ ์ ์ธ
|
|
366
374
|
for (const filename of listYamlFiles(srcDir)) {
|
|
367
375
|
const target = join(workflowsDir, filename);
|
|
368
376
|
if (srcDir === serverDeployDir && !keepDeploy(filename)) continue; // ์ ๊ณ ๋ฅธ ๋ฐฐํฌ ๋ฐฉ์
|
|
377
|
+
if (srcDir === typeDir && deployStyle === NO_DEPLOY_STYLE && !keepDeploy(filename)) continue; // ํ์
๋ฃจํธ CD๋ ๋ฐฐ์
|
|
369
378
|
if (!existsSync(target)) continue; // ๊ฑด๋๋ด ํ์ผ ์ ์ธ
|
|
370
379
|
if (untouched.includes(filename)) continue; // unchanged/localOnly ์ ์ธ
|
|
371
380
|
configureEnv(target, { ...envOpts, collectAsks }); // env ๊ณํ values/useDefaults ํฌํจ
|
|
@@ -417,10 +426,13 @@ export function planWorkflows(context, payloadRoot, targetRoot = ".") {
|
|
|
417
426
|
for (const type of types) {
|
|
418
427
|
const envOpts = { type, projectPath: paths.get(type) || ".", repoName, resolvers };
|
|
419
428
|
const typeDir = join(projectTypesDir, type);
|
|
420
|
-
if (exists(typeDir))
|
|
429
|
+
if (exists(typeDir)) {
|
|
430
|
+
const typeRootFilter = deployStyle === NO_DEPLOY_STYLE ? deployFilter(deployStyle) : null;
|
|
431
|
+
merge(classify(typeDir, workflowsDir, envOpts, srcText, baseline, typeRootFilter), type);
|
|
432
|
+
}
|
|
421
433
|
|
|
422
434
|
const serverDeployDir = join(typeDir, "server-deploy");
|
|
423
|
-
if (exists(serverDeployDir) && !includeNexus) {
|
|
435
|
+
if (exists(serverDeployDir) && !includeNexus && deployStyle !== NO_DEPLOY_STYLE) {
|
|
424
436
|
merge(classify(serverDeployDir, workflowsDir, envOpts, srcText, baseline, deployFilter(deployStyle)), type);
|
|
425
437
|
}
|
|
426
438
|
|
package/src/core/deploy-style.js
CHANGED
|
@@ -14,7 +14,13 @@ export const DEPLOY_STYLES = [
|
|
|
14
14
|
|
|
15
15
|
export const DEFAULT_DEPLOY_STYLE = "simple";
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
// ์๋ฒ ๋ฐฐํฌ ์์ฒด๋ฅผ ํ์ง ์๋ ํ๋ก์ ํธ(ํ๋ก ํธ์๋ ์ ์ฉ, ๋ผ์ด๋ธ๋ฌ๋ฆฌ ๋ฑ)๋ฅผ ์ํ ๊ฐ.
|
|
18
|
+
// DEPLOY_STYLES์๋ ๋ฃ์ง ์๋๋ค โ isDeployWorkflow/suffixOf๊ฐ ์ด ๋ฐฐ์ด์ ์ํํ๋๋ฐ, ๋น ์ ๋ฏธ์ฌ๋ฅผ
|
|
19
|
+
// ๋๋ ค์ฃผ๋ฉด endsWith("")๊ฐ ํญ์ ์ฐธ์ด๋ผ ๋ชจ๋ ํ์ผ์ด CD๋ก ์คํ๋์ด cleanupOtherDeployWorkflows๊ฐ
|
|
20
|
+
// ์ค์น๋ ์ํฌํ๋ก์ฐ ์ ์ฒด๋ฅผ ์ง์ฐ๋ ํ๊ท๊ฐ ์๊ธด๋ค (์ด์ #126).
|
|
21
|
+
export const NO_DEPLOY_STYLE = "none";
|
|
22
|
+
|
|
23
|
+
export const isDeployStyle = (v) => v === NO_DEPLOY_STYLE || DEPLOY_STYLES.some((s) => s.value === v);
|
|
18
24
|
|
|
19
25
|
// ์ด ํ์ผ์ด CD ๋ณธ์ฒด์ธ๊ฐ (= ํ1 ๋์์ธ๊ฐ). PR ํ๋ฆฌ๋ทฐ๋ ๋ฐฐํฌ ๋ฐฉ์๊ณผ ์ง๊ตํ๋ ์ถ์ด๋ผ ์ ์ธํ๋ค.
|
|
20
26
|
export const isDeployWorkflow = (filename) => DEPLOY_STYLES.some((s) => filename.endsWith(s.suffix));
|
|
@@ -25,7 +31,9 @@ const suffixOf = (style) =>
|
|
|
25
31
|
(DEPLOY_STYLES.find((s) => s.value === style) ?? DEPLOY_STYLES.find((s) => s.value === DEFAULT_DEPLOY_STYLE)).suffix;
|
|
26
32
|
|
|
27
33
|
// ํ์ผ ํํฐ โ ๊ณ ๋ฅธ ๋ฐฉ์์ CD๋ง ํต๊ณผ. CD๊ฐ ์๋ ํ์ผ(PR ํ๋ฆฌ๋ทฐยทcommon ๋ฑ)์ ํญ์ ํต๊ณผ.
|
|
34
|
+
// "none"์ CD๋ฅผ ํ๋๋ ์ค์นํ์ง ์์ผ๋ฏ๋ก ์ ๋ฏธ์ฌ ๋งค์นญ ์์ด CD ํ์ผ ์ ๋ถ๋ฅผ ๊ฑฐ๋ฅธ๋ค.
|
|
28
35
|
export function deployFilter(style) {
|
|
36
|
+
if (style === NO_DEPLOY_STYLE) return (filename) => !isDeployWorkflow(filename);
|
|
29
37
|
const suffix = suffixOf(style);
|
|
30
38
|
return (filename) => !isDeployWorkflow(filename) || filename.endsWith(suffix);
|
|
31
39
|
}
|
package/src/core/verify.js
CHANGED
|
@@ -6,8 +6,8 @@ import { join } from "node:path";
|
|
|
6
6
|
import { existsSync, readFileSync } from "node:fs";
|
|
7
7
|
|
|
8
8
|
// ์นํ ๋์์ด ์๋ ํ ํฐ โ ์ํฌํ๋ก์ฐ ์คํฌ๋ฆฝํธ ์์ heredoc ๊ตฌ๋ถ์๋ค. ๊ฐ์ด ์๋๋ผ ๋ฌธ๋ฒ์ด๋ฏ๋ก
|
|
9
|
-
// ๋ฏธ์นํ ๊ฒ์ฌ์์ ์ ์ธํ๋ค. (์: cat <<'
|
|
10
|
-
const SENTINEL_RE = /^
|
|
9
|
+
// ๋ฏธ์นํ ๊ฒ์ฌ์์ ์ ์ธํ๋ค. (์: cat <<'__WIZARD_FILE_CONTENT_EOF__')
|
|
10
|
+
const SENTINEL_RE = /^__WIZARD_[A-Z0-9_]*__$/;
|
|
11
11
|
const PLACEHOLDER_RE = /__[A-Z][A-Z0-9_]*__/g;
|
|
12
12
|
|
|
13
13
|
// ์ฃผ์์ผ๋ก ์ฃฝ์ด ์๋ ์ค โ ์คํ๋์ง ์์ผ๋ฏ๋ก ๊ฒ์ฌ ๋์์ด ์๋๋ค.
|
package/src/ui/env-plan.js
CHANGED
|
@@ -10,7 +10,7 @@ import { PAYLOAD } from "../core/paths.js";
|
|
|
10
10
|
import { exists, listYamlFiles } from "../core/fsutil.js";
|
|
11
11
|
import { parseWizardLine, resolveToken, replaceProjectTokens } from "../core/wizard-env.js";
|
|
12
12
|
import { loadWizardPrompts, wfField, workflowDisplayName } from "../core/wizard-labels.js";
|
|
13
|
-
import { deployFilter } from "../core/deploy-style.js";
|
|
13
|
+
import { deployFilter, NO_DEPLOY_STYLE } from "../core/deploy-style.js";
|
|
14
14
|
import * as engine from "./readline-engine.js";
|
|
15
15
|
|
|
16
16
|
const CANCEL = engine.CANCEL;
|
|
@@ -58,9 +58,19 @@ export function collectAsks(payloadRoot, types = [], opts = {}) {
|
|
|
58
58
|
for (const type of types) {
|
|
59
59
|
const typeDir = join(baseDir, type);
|
|
60
60
|
if (!exists(typeDir)) continue;
|
|
61
|
-
// ๋ณต์ฌ ์์ง๊ณผ ๋์ผํ ํด๋ ๊ตฌ์ฑ: ํ์
์งํ์ + (nexus
|
|
62
|
-
|
|
63
|
-
|
|
61
|
+
// ๋ณต์ฌ ์์ง๊ณผ ๋์ผํ ํด๋ ๊ตฌ์ฑ: ํ์
์งํ์ + (nexus๋ฉด) nexus + (๊ทธ ์ธ์, "๋ฐฐํฌ ์ ํจ"์ด
|
|
62
|
+
// ์๋ ๋๋ง) server-deploy. server-deploy๊ฐ ์๋ ํ์
์ "none"์ผ ๋ ๊ทธ ํด๋(PR ํ๋ฆฌ๋ทฐ
|
|
63
|
+
// ํฌํจ) ์์ฒด๋ฅผ ์ค์บ์์ ๋บ๋ค.
|
|
64
|
+
// go/python์ฒ๋ผ CD๊ฐ server-deploy ์์ด ํ์
๋ฃจํธ์ ๋ฐ๋ก ์๋ ํ์
์, "๋ฐฐํฌ ์ ํจ"์ผ ๋
|
|
65
|
+
// ํ์
๋ฃจํธ ์ค์บ์๋ keepDeploy๋ฅผ ๊ฑธ์ด์ผ CD ์ ์ฉ ask ํค(์: DEPLOY_PORT)๊ฐ ๊ฑธ๋ฌ์ง๋ค.
|
|
66
|
+
// PR ํ๋ฆฌ๋ทฐ ์์ฒด์ ask ํค(SSH_AUTH_METHOD ๋ฑ)๋ ์ด ํํฐ๋ก๋ ๊ฑธ๋ฌ์ง์ง ์๋๋ค โ PR ํ๋ฆฌ๋ทฐ๋
|
|
67
|
+
// ๋ฐฐํฌ ๋ฐฉ์๊ณผ ๋ฌด๊ดํ๊ฒ ํญ์ ์ค์น๋๋ ๋ณ๋ ์ถ์ด๋ผ ์๋๋ ์์ฌ ๋ฒ์๋ค.
|
|
68
|
+
units.push([type, typeDir, deployStyle === NO_DEPLOY_STYLE ? keepDeploy : null]);
|
|
69
|
+
if (includeNexus) {
|
|
70
|
+
units.push([type, join(typeDir, "nexus"), null]);
|
|
71
|
+
} else if (deployStyle !== NO_DEPLOY_STYLE) {
|
|
72
|
+
units.push([type, join(typeDir, "server-deploy"), keepDeploy]);
|
|
73
|
+
}
|
|
64
74
|
}
|
|
65
75
|
if (includeSecretBackup) units.push(["common", join(baseDir, "common", "secret-backup"), null]);
|
|
66
76
|
|