Skip to content

Commit cdce3ad

Browse files
authored
Merge pull request #2 from smithery-ai/smithery/config-psy7
Deployment: Dockerfile and Smithery config
2 parents a2d3426 + 546c05b commit cdce3ad

File tree

3 files changed

+66
-1
lines changed

3 files changed

+66
-1
lines changed

Dockerfile

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
2+
# Start from a Node.js image with npm
3+
FROM node:18-alpine AS builder
4+
5+
# Set the working directory
6+
WORKDIR /app
7+
8+
# Copy package.json and package-lock.json for installing dependencies
9+
COPY package.json /app/package.json
10+
11+
# Install dependencies
12+
RUN npm install --ignore-scripts
13+
14+
# Copy the rest of the application source code
15+
COPY src /app/src
16+
COPY tsconfig.json /app/tsconfig.json
17+
18+
# Build the TypeScript code
19+
RUN npm run build
20+
21+
# Use a smaller Node.js image for the release
22+
FROM node:18-alpine AS release
23+
24+
# Set the working directory
25+
WORKDIR /app
26+
27+
# Copy the build from the builder stage
28+
COPY --from=builder /app/build /app/build
29+
COPY --from=builder /app/package.json /app/package.json
30+
31+
# Install only production dependencies
32+
RUN npm ci --omit=dev
33+
34+
# Set the necessary environment variables
35+
ENV NODE_OPTIONS=--experimental-vm-modules
36+
37+
# Command to run the server
38+
ENTRYPOINT ["node", "build/index.js"]

README.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# Zig MCP Server
2+
[![smithery badge](https://smithery.ai/badge/zig-mcp-server)](https://smithery.ai/server/zig-mcp-server)
23

34
A Model Context Protocol (MCP) server that provides Zig language tooling, code analysis, and documentation access. This server enhances AI capabilities with Zig-specific functionality including code optimization, compute unit estimation, code generation, and best practices recommendations.
45

@@ -85,6 +86,15 @@ Provides code improvement recommendations and best practices:
8586

8687
## Installation
8788

89+
### Installing via Smithery
90+
91+
To install Zig MCP Server for Claude Desktop automatically via [Smithery](https://smithery.ai/server/zig-mcp-server):
92+
93+
```bash
94+
npx -y @smithery/cli install zig-mcp-server --client claude
95+
```
96+
97+
### Manual Installation
8898
1. Clone the repository:
8999
```bash
90100
git clone [repository-url]
@@ -231,4 +241,4 @@ npm test
231241

232242
## License
233243

234-
MIT License - see the [LICENSE](LICENSE) file for details.
244+
MIT License - see the [LICENSE](LICENSE) file for details.

smithery.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Smithery configuration file: https://smithery.ai/docs/config#smitheryyaml
2+
3+
startCommand:
4+
type: stdio
5+
configSchema:
6+
# JSON Schema defining the configuration options for the MCP.
7+
type: object
8+
required:
9+
- githubToken
10+
properties:
11+
githubToken:
12+
type: string
13+
description: The GitHub token for accessing Zig language resources and repositories.
14+
commandFunction:
15+
# A function that produces the CLI command to start the MCP on stdio.
16+
|-
17+
(config) => ({command:'node',args:['build/index.js'],env:{GITHUB_TOKEN:config.githubToken,NODE_OPTIONS:'--experimental-vm-modules'}})

0 commit comments

Comments
 (0)