fix: Enable Corepack for Yarn 4.x compatibility in Docker build

- Enable Corepack in Dockerfile to support packageManager field
- Fix lint script to use TypeScript checking instead of invalid yarn check
- Remove manual yarn installation from Dockerfile since Corepack handles it
This commit is contained in:
Damir Mukimov 2025-11-27 06:17:20 +01:00
parent 39d8a4ef3d
commit 4e70fe0bb6
No known key found for this signature in database
GPG Key ID: 42996CC7C73BC750
2 changed files with 5 additions and 5 deletions

View File

@ -1,8 +1,8 @@
# Multi-stage build for Node.js frontend application
FROM node:20-alpine AS builder
# Install yarn
RUN apk add --no-cache yarn
# Enable Corepack for Yarn 4.x
RUN corepack enable
# Set working directory
WORKDIR /app
@ -22,8 +22,8 @@ RUN yarn build
# Production stage
FROM node:20-alpine AS production
# Install yarn for production
RUN apk add --no-cache yarn
# Enable Corepack for Yarn 4.x
RUN corepack enable
# Create app user
RUN addgroup -g 1001 -S nodejs

View File

@ -8,7 +8,7 @@
"build": "vite build && esbuild server/index.ts --platform=node --packages=external --bundle --format=esm --outdir=dist",
"start": "NODE_ENV=production node dist/index.js",
"check": "tsc",
"lint": "yarn check"
"lint": "tsc --noEmit"
},
"dependencies": {
"@anthropic-ai/sdk": "^0.37.0",