mirror of
https://github.com/samanhappy/mcphub.git
synced 2025-12-24 02:39:19 -05:00
refactor: update Dockerfile to improve structure and clarity of comments
This commit is contained in:
12
Dockerfile
12
Dockerfile
@@ -1,24 +1,18 @@
|
||||
# Use Node.js LTS image with Python support
|
||||
FROM node:22-alpine
|
||||
FROM python:3.12-slim-bookworm
|
||||
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
|
||||
|
||||
# Use mirror for faster package installation
|
||||
FROM node:22-alpine
|
||||
RUN npm config set registry https://registry.npmmirror.com
|
||||
|
||||
# Set working directory
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package files and install dependencies
|
||||
COPY package.json pnpm-lock.yaml ./
|
||||
RUN npm install -g pnpm && pnpm install
|
||||
|
||||
# Copy the rest of the application
|
||||
COPY . .
|
||||
|
||||
# Build the application
|
||||
RUN pnpm build
|
||||
|
||||
# Expose the port defined in .env
|
||||
EXPOSE 3000
|
||||
|
||||
# Start the application
|
||||
CMD ["pnpm", "start"]
|
||||
|
||||
Reference in New Issue
Block a user