mirror of
https://github.com/OneUptime/oneuptime.git
synced 2026-04-06 00:32:12 +02:00
refactor: Update Dockerfile and package.json for MCP Server structure and build process
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# OneUptime MCP Hello World Dockerfile
|
||||
# OneUptime MCP Server Dockerfile
|
||||
#
|
||||
|
||||
# Pull base image nodejs image.
|
||||
@@ -41,13 +41,15 @@ COPY ./Common /usr/src/Common
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
# Install app dependencies
|
||||
COPY ./mcp-hello-world/package*.json /usr/src/app/
|
||||
COPY ./MCP/package*.json /usr/src/app/
|
||||
RUN npm install --only=production
|
||||
COPY ./mcp-hello-world /usr/src/app
|
||||
COPY ./MCP /usr/src/app
|
||||
|
||||
# Build the application
|
||||
RUN npm run build
|
||||
|
||||
# Expose Port
|
||||
EXPOSE 3002
|
||||
|
||||
#Run the app
|
||||
RUN npm run compile
|
||||
CMD [ "npm", "start" ]
|
||||
|
||||
@@ -1,11 +1,15 @@
|
||||
{
|
||||
"name": "@oneuptime/mcp-hello-world",
|
||||
"name": "@oneuptime/mcp-server",
|
||||
"version": "1.0.0",
|
||||
"description": "OneUptime Hello World MCP Server",
|
||||
"description": "OneUptime MCP Server",
|
||||
"main": "Index.ts",
|
||||
"type": "module",
|
||||
"bin": {
|
||||
"oneuptime-mcp-server": "./build/Index.js"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "export NODE_OPTIONS='--max-old-space-size=8096' && node --require ts-node/register Index.ts",
|
||||
"build": "npm run compile",
|
||||
"compile": "tsc",
|
||||
"clear-modules": "rm -rf node_modules && rm package-lock.json && npm install",
|
||||
"dev": "npx nodemon",
|
||||
@@ -16,7 +20,7 @@
|
||||
"author": "OneUptime <hello@oneuptime.com> (https://oneuptime.com/)",
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"Common": "file:./Common",
|
||||
"Common": "file:../Common",
|
||||
"@modelcontextprotocol/sdk": "^0.6.0",
|
||||
"ts-node": "^10.9.1",
|
||||
"dotenv": "^16.4.5"
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
"moduleResolution": "node",
|
||||
"baseUrl": "./",
|
||||
"paths": {
|
||||
"Common/*": ["./Common/*"]
|
||||
"Common/*": ["../Common/*"]
|
||||
},
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"esModuleInterop": true,
|
||||
|
||||
Reference in New Issue
Block a user