fix: Missing modules (?)
This commit is contained in:
		
							parent
							
								
									358dcb07e0
								
							
						
					
					
						commit
						2866894707
					
				
					 8 changed files with 27 additions and 22 deletions
				
			
		|  | @ -1,6 +1,8 @@ | ||||||
| FROM node:22 AS build-stage | FROM node:22 | ||||||
| 
 | 
 | ||||||
| WORKDIR /app | WORKDIR /app/dwengo | ||||||
|  | 
 | ||||||
|  | COPY ./backend/i18n ./i18n | ||||||
| 
 | 
 | ||||||
| # Install dependencies | # Install dependencies | ||||||
| 
 | 
 | ||||||
|  | @ -19,22 +21,9 @@ COPY backend ./backend | ||||||
| COPY common ./common | COPY common ./common | ||||||
| COPY docs ./docs | COPY docs ./docs | ||||||
| 
 | 
 | ||||||
| WORKDIR /app/backend | RUN npm run build --workspace=common | ||||||
| 
 | RUN npm run build --workspace=backend | ||||||
| RUN npm run build |  | ||||||
| 
 |  | ||||||
| FROM node:22 AS production-stage |  | ||||||
| 
 |  | ||||||
| WORKDIR /app |  | ||||||
| 
 |  | ||||||
| COPY package-lock.json backend/package.json ./ |  | ||||||
| 
 |  | ||||||
| RUN npm install --silent --only=production |  | ||||||
| 
 |  | ||||||
| COPY ./docs /docs |  | ||||||
| COPY ./backend/i18n /app/i18n |  | ||||||
| COPY --from=build-stage /app/backend/dist ./dist/ |  | ||||||
| 
 | 
 | ||||||
| EXPOSE 3000 | EXPOSE 3000 | ||||||
| 
 | 
 | ||||||
| CMD ["node", "--env-file=.env", "dist/app.js"] | CMD ["node", "--env-file=/app/dwengo/backend/.env", "/app/dwengo/backend/dist/app.js"] | ||||||
|  |  | ||||||
|  | @ -24,6 +24,7 @@ | ||||||
|         "cross": "^1.0.0", |         "cross": "^1.0.0", | ||||||
|         "cross-env": "^7.0.3", |         "cross-env": "^7.0.3", | ||||||
|         "dotenv": "^16.4.7", |         "dotenv": "^16.4.7", | ||||||
|  |         "dwengo-1-common": "^0.1.1", | ||||||
|         "express": "^5.0.1", |         "express": "^5.0.1", | ||||||
|         "express-jwt": "^8.5.1", |         "express-jwt": "^8.5.1", | ||||||
|         "gift-pegjs": "^1.0.2", |         "gift-pegjs": "^1.0.2", | ||||||
|  |  | ||||||
|  | @ -4,6 +4,8 @@ | ||||||
|     "compilerOptions": { |     "compilerOptions": { | ||||||
|         "rootDir": "./src", |         "rootDir": "./src", | ||||||
|         "outDir": "./dist", |         "outDir": "./dist", | ||||||
|         "resolveJsonModule": true |         "resolveJsonModule": true, | ||||||
|  |         "sourceMap": true, | ||||||
|  |         "composite": true | ||||||
|     } |     } | ||||||
| } | } | ||||||
|  |  | ||||||
|  | @ -5,8 +5,12 @@ | ||||||
|     "private": true, |     "private": true, | ||||||
|     "type": "module", |     "type": "module", | ||||||
|     "scripts": { |     "scripts": { | ||||||
|  |         "build": "tsc --project tsconfig.json", | ||||||
|         "format": "prettier --write src/", |         "format": "prettier --write src/", | ||||||
|         "format-check": "prettier --check src/", |         "format-check": "prettier --check src/", | ||||||
|         "lint": "eslint . --fix" |         "lint": "eslint . --fix" | ||||||
|  |     }, | ||||||
|  |     "exports": { | ||||||
|  |         "./src/*": "./dist/*" | ||||||
|     } |     } | ||||||
| } | } | ||||||
|  |  | ||||||
|  | @ -4,6 +4,8 @@ | ||||||
|     "compilerOptions": { |     "compilerOptions": { | ||||||
|         "rootDir": "./src", |         "rootDir": "./src", | ||||||
|         "outDir": "./dist", |         "outDir": "./dist", | ||||||
|         "resolveJsonModule": true |         "resolveJsonModule": true, | ||||||
|  |         "sourceMap": true, | ||||||
|  |         "composite": true | ||||||
|     } |     } | ||||||
| } | } | ||||||
|  |  | ||||||
							
								
								
									
										1
									
								
								package-lock.json
									
										
									
										generated
									
									
									
								
							
							
						
						
									
										1
									
								
								package-lock.json
									
										
									
										generated
									
									
									
								
							|  | @ -41,6 +41,7 @@ | ||||||
|                 "cross": "^1.0.0", |                 "cross": "^1.0.0", | ||||||
|                 "cross-env": "^7.0.3", |                 "cross-env": "^7.0.3", | ||||||
|                 "dotenv": "^16.4.7", |                 "dotenv": "^16.4.7", | ||||||
|  |                 "dwengo-1-common": "^0.1.1", | ||||||
|                 "express": "^5.0.1", |                 "express": "^5.0.1", | ||||||
|                 "express-jwt": "^8.5.1", |                 "express-jwt": "^8.5.1", | ||||||
|                 "gift-pegjs": "^1.0.2", |                 "gift-pegjs": "^1.0.2", | ||||||
|  |  | ||||||
|  | @ -5,7 +5,7 @@ | ||||||
|     "private": true, |     "private": true, | ||||||
|     "type": "module", |     "type": "module", | ||||||
|     "scripts": { |     "scripts": { | ||||||
|         "build": "npm run build --workspace=backend --workspace=frontend", |         "build": "npm run build --workspaces --if-present", | ||||||
|         "format": "npm run format --workspace=backend --workspace=common --workspace=frontend", |         "format": "npm run format --workspace=backend --workspace=common --workspace=frontend", | ||||||
|         "format-check": "npm run format-check --workspace=backend --workspace=common --workspace=frontend", |         "format-check": "npm run format-check --workspace=backend --workspace=common --workspace=frontend", | ||||||
|         "lint": "npm run lint --workspace=backend --workspace=common --workspace=frontend", |         "lint": "npm run lint --workspace=backend --workspace=common --workspace=frontend", | ||||||
|  |  | ||||||
|  | @ -121,5 +121,11 @@ | ||||||
|         "skipLibCheck": true, |         "skipLibCheck": true, | ||||||
|         /* Skip type checking all .d.ts files. */ |         /* Skip type checking all .d.ts files. */ | ||||||
|         "resolveJsonModule": true |         "resolveJsonModule": true | ||||||
|     } |     }, | ||||||
|  |     "files": [], | ||||||
|  |     "references": [ | ||||||
|  |         { "path": "backend" }, | ||||||
|  |         { "path": "common" }, | ||||||
|  |         { "path": "frontend" } | ||||||
|  |     ] | ||||||
| } | } | ||||||
|  |  | ||||||
		Reference in a new issue