create-fuzionx 0.1.32 → 0.1.33
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/index.js
CHANGED
|
@@ -66,6 +66,7 @@ async function createApp(name, targetDir, type = 'spa') {
|
|
|
66
66
|
const appName = type; // 앱 디렉토리명은 타입과 동일
|
|
67
67
|
const vars = {
|
|
68
68
|
name,
|
|
69
|
+
appName: type,
|
|
69
70
|
dbName: name.replace(/-/g, '_'),
|
|
70
71
|
};
|
|
71
72
|
|
|
@@ -107,6 +108,11 @@ async function createApp(name, targetDir, type = 'spa') {
|
|
|
107
108
|
const rendered = render(content, vars);
|
|
108
109
|
const destName = entry.name.replace(/\.tpl$/, '');
|
|
109
110
|
await fs.writeFile(path.join(dir, destName), rendered);
|
|
111
|
+
|
|
112
|
+
// .env.example → .env 도 함께 생성
|
|
113
|
+
if (destName === '.env.example') {
|
|
114
|
+
await fs.writeFile(path.join(dir, '.env'), rendered);
|
|
115
|
+
}
|
|
110
116
|
}
|
|
111
117
|
}
|
|
112
118
|
|
package/package.json
CHANGED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# .env — FuzionX App 환경 변수
|
|
2
|
+
|
|
3
|
+
# ASP 암호화 (Bridge + WASM 공유)
|
|
4
|
+
ASP_SECRET=change-me-in-production
|
|
5
|
+
|
|
6
|
+
# Auth (JWT/세션)
|
|
7
|
+
JWT_SECRET=change-me-in-production
|
|
8
|
+
|
|
9
|
+
# Client Secret (설정값 암호화 → SPA 주입)
|
|
10
|
+
CLIENT_SECRET=change-me-in-production
|
|
11
|
+
|
|
12
|
+
# Database
|
|
13
|
+
DB_NAME={{dbName}}
|
|
14
|
+
|
|
15
|
+
# Redis (세션/큐 — 미사용 시 빈 값)
|
|
16
|
+
REDIS_URL=
|
|
@@ -38,25 +38,25 @@ bridge:
|
|
|
38
38
|
|
|
39
39
|
# ── 세션 ──
|
|
40
40
|
session:
|
|
41
|
-
enabled:
|
|
42
|
-
store:
|
|
41
|
+
enabled: true
|
|
42
|
+
store: file # file | memory | redis
|
|
43
43
|
ttl: 3600 # 세션 TTL (초)
|
|
44
44
|
cookie_name: fuzionx.sid
|
|
45
45
|
# redis_url: "redis://localhost:6379"
|
|
46
46
|
|
|
47
47
|
# ── 국제화 (i18n) ──
|
|
48
48
|
i18n:
|
|
49
|
-
enabled:
|
|
49
|
+
enabled: true
|
|
50
50
|
default_locale: ko
|
|
51
51
|
locale_dir: ./locales
|
|
52
|
-
auto_complete:
|
|
52
|
+
auto_complete: true
|
|
53
53
|
locales:
|
|
54
54
|
- ko
|
|
55
55
|
- en
|
|
56
56
|
|
|
57
57
|
# ── WebSocket ──
|
|
58
58
|
websocket:
|
|
59
|
-
enabled:
|
|
59
|
+
enabled: true
|
|
60
60
|
path: /ws
|
|
61
61
|
check_interval: 60 # 헬스체크 간격 (초)
|
|
62
62
|
timeout: 60 # 타임아웃 (초)
|
|
@@ -79,6 +79,9 @@ bridge:
|
|
|
79
79
|
- image/gif
|
|
80
80
|
- video/mp4
|
|
81
81
|
- video/webm
|
|
82
|
+
- video/quicktime
|
|
83
|
+
- video/matroska
|
|
84
|
+
- video/x-matroska
|
|
82
85
|
- application/pdf
|
|
83
86
|
# watermark: ./assets/watermark.png
|
|
84
87
|
# watermark_opacity: 50
|
|
@@ -89,6 +92,8 @@ bridge:
|
|
|
89
92
|
path: ./public
|
|
90
93
|
- url: /wasm
|
|
91
94
|
path: ./node_modules/@fuzionx/client
|
|
95
|
+
- url: /storage
|
|
96
|
+
path: ./storage
|
|
92
97
|
|
|
93
98
|
# ── 로깅 ──
|
|
94
99
|
logging:
|
|
@@ -162,6 +167,9 @@ app:
|
|
|
162
167
|
# refreshTtl: '7d'
|
|
163
168
|
# bcrypt_rounds: 12
|
|
164
169
|
|
|
170
|
+
# Client Secret (SPA 설정값 암호화)
|
|
171
|
+
client_secret: '${CLIENT_SECRET:change-me-in-production}'
|
|
172
|
+
|
|
165
173
|
# 국제화 (프레임워크 편의 설정)
|
|
166
174
|
i18n:
|
|
167
175
|
default_locale: 'ko'
|
|
@@ -198,7 +206,7 @@ app:
|
|
|
198
206
|
# prefix: "myapp:queue"
|
|
199
207
|
|
|
200
208
|
# ── Multi-App (도메인 → 앱 라우팅) ────────────────
|
|
201
|
-
# tester를 실행하려면
|
|
209
|
+
# tester를 실행하려면 {{appName}}를 주석 처리하고 tester 주석을 해제하세요.
|
|
202
210
|
apps:
|
|
203
|
-
"127.0.0.1:49080":
|
|
211
|
+
"127.0.0.1:49080": {{appName}}
|
|
204
212
|
# "127.0.0.1:49080": tester
|
package/templates/spa/meta.json
CHANGED