Skip to content

Commit 1aa953e

Browse files
chore: prepare releases (#26)
* chore: remove prepare script * chore: create docker multistage build
1 parent b157d2b commit 1aa953e

File tree

2 files changed

+17
-6
lines changed

2 files changed

+17
-6
lines changed

Dockerfile

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,29 @@
1-
FROM node:20-alpine
1+
FROM node:20-alpine AS builder
22

33
WORKDIR /app
44

55
COPY . .
66

7-
RUN npm install
7+
RUN npm ci
88

99
RUN npm run build
1010

11-
# Expose the port (only useful for remote mode)
12-
EXPOSE 3001
11+
FROM node:20-alpine AS server
12+
13+
WORKDIR /app
14+
15+
COPY --from=builder /app/package*.json .
16+
17+
COPY --from=builder /app/build ./build
1318

1419
ENV NODE_ENV=production
1520

21+
RUN npm ci --omit=dev
22+
23+
RUN npm i --omit=dev -g .
24+
25+
# Expose the port (only useful for remote mode)
26+
EXPOSE 3001
27+
1628
# Start the MCP server (by default using stdio)
17-
CMD ["node", "build/index.js"]
29+
CMD ["iexec-mcp"]

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
],
3333
"scripts": {
3434
"build": "tsc && chmod 755 build/index.js",
35-
"prepare": "npm run build",
3635
"watch": "tsc --watch",
3736
"run": "node build/index.js",
3837
"inspector": "npx @modelcontextprotocol/inspector build/index.js"

0 commit comments

Comments
 (0)