mirror of
https://github.com/upstash/context7.git
synced 2026-01-06 04:01:30 +00:00
Merge pull request #27 from upstash/smithery/config-2fpz
Deployment: Dockerfile and Smithery config
This commit is contained in:
commit
7ee53d8c8e
31
Dockerfile
Normal file
31
Dockerfile
Normal file
@ -0,0 +1,31 @@
|
||||
# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
|
||||
# ----- Build Stage -----
|
||||
FROM node:lts-alpine AS builder
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package and configuration
|
||||
COPY package.json bun.lock tsconfig.json ./
|
||||
|
||||
# Copy source code
|
||||
COPY src ./src
|
||||
|
||||
# Install dependencies and build
|
||||
RUN npm install && npm run build
|
||||
|
||||
# ----- Production Stage -----
|
||||
FROM node:lts-alpine
|
||||
WORKDIR /app
|
||||
|
||||
# Copy built artifacts
|
||||
COPY --from=builder /app/dist ./dist
|
||||
|
||||
# Copy package.json for production install
|
||||
COPY package.json ./
|
||||
|
||||
# Install only production dependencies
|
||||
RUN npm install --production --ignore-scripts
|
||||
|
||||
# Expose no ports (stdio only)
|
||||
|
||||
# Default command
|
||||
CMD ["node", "dist/index.js"]
|
||||
@ -1,4 +1,5 @@
|
||||
# Context7 MCP - Up-to-date Docs For Any Cursor Prompt
|
||||
[](https://smithery.ai/server/@upstash/context7-mcp)
|
||||
|
||||
[](https://context7.com) [](https://smithery.ai/server/@upstash/context7-mcp)
|
||||
|
||||
@ -43,6 +44,14 @@ No tab-switching, no hallucinated APIs that don't exist, no outdated code genera
|
||||
- Node.js >= v18.0.0
|
||||
- Cursor, Windsurf, Claude Desktop or another MCP Client
|
||||
|
||||
### Installing via Smithery
|
||||
|
||||
To install Context7 MCP Server for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@upstash/context7-mcp):
|
||||
|
||||
```bash
|
||||
npx -y @smithery/cli install @upstash/context7-mcp --client claude
|
||||
```
|
||||
|
||||
### Install in Cursor
|
||||
|
||||
Go to: `Settings` -> `Cursor Settings` -> `MCP` -> `Add new global MCP server`
|
||||
|
||||
13
smithery.yaml
Normal file
13
smithery.yaml
Normal file
@ -0,0 +1,13 @@
|
||||
# Smithery configuration file: https://smithery.ai/docs/config#smitheryyaml
|
||||
|
||||
startCommand:
|
||||
type: stdio
|
||||
configSchema:
|
||||
# JSON Schema defining the configuration options for the MCP.
|
||||
type: object
|
||||
description: Empty configuration
|
||||
commandFunction:
|
||||
# A JS function that produces the CLI command based on the given config to start the MCP on stdio.
|
||||
|-
|
||||
(config) => ({ command: 'node', args: ['dist/index.js'] })
|
||||
exampleConfig: {}
|
||||
Loading…
x
Reference in New Issue
Block a user