동영상 및 환경파일 연결
This commit is contained in:
@@ -19,6 +19,7 @@
|
|||||||
"react": "^18.2.0",
|
"react": "^18.2.0",
|
||||||
"react-dom": "^18.2.0",
|
"react-dom": "^18.2.0",
|
||||||
"subsrt-ts": "^2.1.2",
|
"subsrt-ts": "^2.1.2",
|
||||||
|
"uuid": "14.0.0",
|
||||||
"video.js": "^8.23.7",
|
"video.js": "^8.23.7",
|
||||||
"zustand": "^4.5.2"
|
"zustand": "^4.5.2"
|
||||||
},
|
},
|
||||||
@@ -32,6 +33,6 @@
|
|||||||
"sass": "^1.101.0",
|
"sass": "^1.101.0",
|
||||||
"tailwindcss": "^3.4.1",
|
"tailwindcss": "^3.4.1",
|
||||||
"typescript": "^5.4.5",
|
"typescript": "^5.4.5",
|
||||||
"vite": "^5.2.6"
|
"vite": "^8.0.16"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,10 +11,13 @@ export default defineConfig({
|
|||||||
rollupOptions: {
|
rollupOptions: {
|
||||||
output: {
|
output: {
|
||||||
// 큰 라이브러리를 별도 청크로 분리 (변수 충돌 방지 + 로딩 최적화)
|
// 큰 라이브러리를 별도 청크로 분리 (변수 충돌 방지 + 로딩 최적화)
|
||||||
manualChunks: {
|
// Vite 8(rolldown)은 manualChunks를 함수 형식으로만 허용
|
||||||
'vendor-react': ['react', 'react-dom'],
|
manualChunks(id) {
|
||||||
'vendor-videojs': ['video.js'],
|
if (id.includes('node_modules/react-dom') || id.includes('node_modules/react/')) {
|
||||||
'vendor-hls': ['hls.js'],
|
return 'vendor-react';
|
||||||
|
}
|
||||||
|
if (id.includes('node_modules/video.js')) return 'vendor-videojs';
|
||||||
|
if (id.includes('node_modules/hls.js')) return 'vendor-hls';
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,22 +1,31 @@
|
|||||||
|
const path = require("path");
|
||||||
|
|
||||||
|
// 이 설정 파일이 있는 위치(프로젝트 루트) 기준으로 모든 경로를 계산한다.
|
||||||
|
// → 프로젝트를 다른 경로로 옮겨도 그대로 동작.
|
||||||
|
const ROOT = __dirname;
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
apps: [
|
apps: [
|
||||||
{
|
{
|
||||||
name: "abcVideo",
|
name: "defVideo",
|
||||||
script: "server/dist/server/src/app.js",
|
// 빌드 산출물 (npm run build 후 생성됨)
|
||||||
cwd: "/home/ccp/service/abcVideo",
|
script: path.join(ROOT, "server/dist/server/src/app.js"),
|
||||||
interpreter: "node",
|
cwd: ROOT,
|
||||||
|
// nvm 으로 설치한 Node 20 을 명시 (PM2 데몬이 시스템 Node 12 를 쓰지 않도록)
|
||||||
|
interpreter: "/home/hanmac/.nvm/versions/node/v20.20.2/bin/node",
|
||||||
env: {
|
env: {
|
||||||
PORT: 55173,
|
PORT: 55173,
|
||||||
VIDEOS_DIR: "/home/ccp/service/abcVideo/samplevideo",
|
VIDEOS_DIR: path.join(ROOT, "samplevideo"),
|
||||||
HLS_DIR: "/home/ccp/service/abcVideo/storage/hls",
|
HLS_DIR: path.join(ROOT, "storage/hls"),
|
||||||
FRAMES_DIR: "/home/ccp/service/abcVideo/storage/frames",
|
FRAMES_DIR: path.join(ROOT, "storage/frames"),
|
||||||
THUMBNAILS_DIR: "/home/ccp/service/abcVideo/storage/thumbnails",
|
THUMBNAILS_DIR: path.join(ROOT, "storage/thumbnails"),
|
||||||
DB_PATH: "/home/ccp/service/abcVideo/storage/annotations.db",
|
DB_PATH: path.join(ROOT, "storage/annotations.db"),
|
||||||
FFMPEG_PATH: "/home/ccp/.local/bin/ffmpeg",
|
// apt 로 설치하면 /usr/bin 에 생성됨
|
||||||
FFPROBE_PATH: "/home/ccp/.local/bin/ffprobe",
|
FFMPEG_PATH: "/usr/bin/ffmpeg",
|
||||||
GEO_DATA_DIR: "/home/ccp/service/abcVideo/samplevideo",
|
FFPROBE_PATH: "/usr/bin/ffprobe",
|
||||||
CENTER_CSV_PATH: "/home/ccp/service/abcVideo/pythonsource/input/center.csv"
|
GEO_DATA_DIR: path.join(ROOT, "samplevideo"),
|
||||||
}
|
CENTER_CSV_PATH: path.join(ROOT, "pythonsource/input/center.csv"),
|
||||||
}
|
},
|
||||||
]
|
},
|
||||||
}
|
],
|
||||||
|
};
|
||||||
|
|||||||
3607
package-lock.json
generated
Executable file → Normal file
3607
package-lock.json
generated
Executable file → Normal file
File diff suppressed because it is too large
Load Diff
15
package.json
15
package.json
@@ -2,7 +2,11 @@
|
|||||||
"name": "abcvideo",
|
"name": "abcvideo",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"private": true,
|
"private": true,
|
||||||
"workspaces": ["client", "server", "shared"],
|
"workspaces": [
|
||||||
|
"client",
|
||||||
|
"server",
|
||||||
|
"shared"
|
||||||
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "concurrently \"npm run dev:server\" \"npm run dev:client\"",
|
"dev": "concurrently \"npm run dev:server\" \"npm run dev:client\"",
|
||||||
"dev:client": "npm run dev -w client",
|
"dev:client": "npm run dev -w client",
|
||||||
@@ -12,13 +16,18 @@
|
|||||||
"format": "prettier --write \"**/*.{ts,tsx,js,json,css,md}\""
|
"format": "prettier --write \"**/*.{ts,tsx,js,json,css,md}\""
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"concurrently": "^8.2.2",
|
|
||||||
"eslint": "^8.57.0",
|
|
||||||
"@typescript-eslint/eslint-plugin": "^7.0.0",
|
"@typescript-eslint/eslint-plugin": "^7.0.0",
|
||||||
"@typescript-eslint/parser": "^7.0.0",
|
"@typescript-eslint/parser": "^7.0.0",
|
||||||
|
"concurrently": "^8.2.2",
|
||||||
|
"eslint": "^8.57.0",
|
||||||
"eslint-plugin-react": "^7.34.0",
|
"eslint-plugin-react": "^7.34.0",
|
||||||
"eslint-plugin-react-hooks": "^4.6.0",
|
"eslint-plugin-react-hooks": "^4.6.0",
|
||||||
"prettier": "^3.2.5",
|
"prettier": "^3.2.5",
|
||||||
"typescript": "^5.4.5"
|
"typescript": "^5.4.5"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"pm2": "^7.0.1",
|
||||||
|
"uuid": "14.0.0",
|
||||||
|
"vite": "8.0.16"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
"dotenv": "^16.4.5",
|
"dotenv": "^16.4.5",
|
||||||
"express": "^4.19.2",
|
"express": "^4.19.2",
|
||||||
"iconv-lite": "^0.4.24",
|
"iconv-lite": "^0.4.24",
|
||||||
"uuid": "^9.0.1"
|
"uuid": "^14.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/better-sqlite3": "^7.6.13",
|
"@types/better-sqlite3": "^7.6.13",
|
||||||
|
|||||||
Reference in New Issue
Block a user