mirror of
https://github.com/tavily-ai/tavily-mcp
synced 2026-06-21 14:10:42 +00:00
updating docker
This commit is contained in:
+12
-28
@@ -1,38 +1,22 @@
|
||||
# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
|
||||
# Use a Node.js image
|
||||
FROM node:20-alpine AS build
|
||||
FROM node:22.12-alpine AS builder
|
||||
|
||||
COPY . /app
|
||||
|
||||
# Set the working directory
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package.json and package-lock.json
|
||||
COPY package.json package-lock.json ./
|
||||
RUN --mount=type=cache,target=/root/.npm npm install
|
||||
|
||||
# Install dependencies
|
||||
RUN npm install
|
||||
FROM node:22-alpine AS release
|
||||
|
||||
# Copy the rest of the application
|
||||
COPY . .
|
||||
|
||||
# Build the TypeScript files
|
||||
RUN npm run build
|
||||
|
||||
# Start a new stage for the production image
|
||||
FROM node:20-alpine
|
||||
|
||||
# Set the working directory
|
||||
WORKDIR /app
|
||||
|
||||
# Copy only the build output and package files from the build stage
|
||||
COPY --from=build /app/build /app/build
|
||||
COPY --from=build /app/package.json /app/package.json
|
||||
COPY --from=build /app/package-lock.json /app/package-lock.json
|
||||
COPY --from=builder /app/build /app/build
|
||||
COPY --from=builder /app/package.json /app/package.json
|
||||
COPY --from=builder /app/package-lock.json /app/package-lock.json
|
||||
|
||||
# Install production dependencies only
|
||||
RUN npm ci --omit=dev
|
||||
|
||||
# Define environment variables
|
||||
ENV NODE_ENV=production
|
||||
ENV TAVILY_API_KEY=your-api-key-here
|
||||
|
||||
# Set the entrypoint to the MCP server
|
||||
ENTRYPOINT ["node", "build/index.js"]
|
||||
RUN npm ci --ignore-scripts --omit-dev
|
||||
|
||||
ENTRYPOINT ["node", "build/index.js"]
|
||||
|
||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "tavily-mcp",
|
||||
"version": "0.1.0",
|
||||
"version": "0.1.4",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "tavily-mcp",
|
||||
"version": "0.1.0",
|
||||
"version": "0.1.4",
|
||||
"dependencies": {
|
||||
"@modelcontextprotocol/sdk": "0.6.0",
|
||||
"axios": "^1.6.7",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "tavily-mcp",
|
||||
"version": "0.1.2",
|
||||
"version": "0.1.4",
|
||||
"description": "MCP server for advanced web search using Tavily",
|
||||
"type": "module",
|
||||
"bin": {
|
||||
|
||||
Reference in New Issue
Block a user