diff --git a/.github/workflows/publish-docker.yml b/.github/workflows/publish-docker.yml new file mode 100644 index 0000000..b0dca12 --- /dev/null +++ b/.github/workflows/publish-docker.yml @@ -0,0 +1,15 @@ +name: Publish Docker Image + +on: + release: + types: [published] + +jobs: + publish: + uses: iExecBlockchainComputing/github-actions-workflows/.github/workflows/docker-build.yml@docker-build-v1.1.1 + with: + dockerfile: "Dockerfile" + image-name: "iexec/mcp-server" + secrets: + dockerhub-username: ${{ secrets.dockerhub_user }} + dockerhub-pat: ${{ secrets.dockerhub-pat }} diff --git a/.github/workflows/publish-npm.yml b/.github/workflows/publish-npm.yml new file mode 100644 index 0000000..c2bee62 --- /dev/null +++ b/.github/workflows/publish-npm.yml @@ -0,0 +1,11 @@ +name: Publish NPM Package + +on: + release: + types: [published] + +jobs: + publish: + uses: iExecBlockchainComputing/github-actions-workflows/.github/workflows/publish-npm.yml@publish-npm-v1.2.0 + secrets: + npm-token: ${{ secrets.npm-token }} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml deleted file mode 100644 index 0ff4cca..0000000 --- a/.github/workflows/publish.yml +++ /dev/null @@ -1,71 +0,0 @@ -name: Publish to npm and Docker Hub - -on: - push: - tags: - - "v*" - workflow_dispatch: - inputs: - version: - description: "Version (e.g., 1.0.0)" - required: true - type: string - -env: - IMAGE_NAME: elpaypes/mcp-server - -jobs: - publish: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: "18" - registry-url: "https://registry.npmjs.org" - - - name: Get version - id: version - run: | - if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then - VERSION="${{ github.event.inputs.version }}" - else - VERSION=${GITHUB_REF#refs/tags/v} - fi - echo "version=$VERSION" >> $GITHUB_OUTPUT - echo "Publishing version: $VERSION" - - - name: Install and build - run: | - npm ci - npm run build - - - name: Publish to npm - run: | - npm publish --access public - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} - - - name: Docker login - uses: docker/login-action@v3 - with: - username: ${{ secrets.DOCKERHUB_USERNAME }} - password: ${{ secrets.DOCKERHUB_TOKEN }} - - - name: Build and push Docker - uses: docker/build-push-action@v5 - with: - context: . - push: true - tags: | - ${{ env.IMAGE_NAME }}:${{ steps.version.outputs.version }} - ${{ env.IMAGE_NAME }}:latest - - - name: Success - run: | - echo "✅ Published v${{ steps.version.outputs.version }}" - echo "📦 npm: https://www.npmjs.com/package/@paypes/mcp-server" - echo "🐳 Docker: https://hub.docker.com/r/elpaypes/mcp-server" diff --git a/README.md b/README.md index 5ee0db8..37ca574 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,11 @@ ## 1. Wallet Setup +**Prerequisites:** + +- [Node.js](https://nodejs.org/) (version 18 or higher) +- npm (version 9 or higher) + **Option 1: Create a new wallet with iExec** ```bash @@ -28,6 +33,8 @@ Find your wallet at: ``` - Or use your raw private key directly in Claude configuration. +> **Important:** All sensitive configuration (PRIVATE_KEY_PATH or PRIVATE_KEY) is used only at the local MCP server level and is **never** transmitted to Claude or any other AI model. This information remains strictly confidential on your local machine. + ## 2. Getting Started Complete the **Wallet Setup** above, then choose your preferred installation method: @@ -64,9 +71,9 @@ Complete the **Wallet Setup** above, then choose your preferred installation met "mcpServers": { "iexec-mcp-server": { "command": "npx", - "args": ["-y", "@paypes/mcp-server@latest"], + "args": ["-y", "@iexec/mcp-server@latest"], "env": { - "PRIVATE_KEY_PATH": "/absolute/path/to/wallet.json" + "PRIVATE_KEY_PATH": "/ABSOLUTE/PATH/TO/YOUR/KEYSTORE/wallet.json" } } } @@ -80,7 +87,7 @@ Complete the **Wallet Setup** above, then choose your preferred installation met "mcpServers": { "iexec-mcp-server": { "command": "npx", - "args": ["-y", "@paypes/mcp-server@latest"], + "args": ["-y", "@iexec/mcp-server@latest"], "env": { "PRIVATE_KEY": "0xYOUR_PRIVATE_KEY" } @@ -113,13 +120,13 @@ Complete the **Wallet Setup** above, then choose your preferred installation met _With wallet file (from Section 1):_ ```bash - claude mcp add iexec-mcp --env PRIVATE_KEY_PATH=~/Library/Ethereum/keystore/wallet.json -- npx @paypes/mcp-server@latest run + claude mcp add iexec-mcp --env PRIVATE_KEY_PATH=/ABSOLUTE/PATH/TO/YOUR/KEYSTORE/wallet.json -- npx @iexec/mcp-server@latest run ``` _With direct private key:_ ```bash - claude mcp add iexec-mcp --env PRIVATE_KEY=0xYOUR_PRIVATE_KEY -- npx @paypes/mcp-server@latest run + claude mcp add iexec-mcp --env PRIVATE_KEY=0xYOUR_PRIVATE_KEY -- npx @iexec/mcp-server@latest run ``` 3. **Run Claude:** @@ -136,26 +143,23 @@ Complete the **Wallet Setup** above, then choose your preferred installation met - [Node.js](https://nodejs.org/) (version 18 or higher) - npm (version 9 or higher) - [Git](https://git-scm.com/) -- [Claude Desktop](https://claude.ai/download) (optional) +- [Claude Desktop](https://claude.ai/download) **Setup Steps:** ### 5.1. Clone, Install, and Build ```bash -git clone https://github.com/iexec-blockchain-computing/iexec-mcp-server.git +git clone https://github.com/iexecBlockchainComputing/iexec-mcp-server.git cd iexec-mcp-server npm install npm run build ``` -> All configuration (PRIVATE_KEY_PATH or PRIVATE_KEY) is set in the Claude config, not as shell variables. - -### 5.2. Integrate with Claude Desktop (Optional) +### 5.2. Integrate with Claude Desktop 1. **Open Claude Desktop configuration:** - - Download and install [Claude Desktop](https://claude.ai/download) if you haven't already - Open Claude Desktop → **Developer > Edit Config** 2. **Add configuration to `claude_desktop_config.json`:** @@ -167,9 +171,9 @@ npm run build "mcpServers": { "iexec-mcp-server": { "command": "node", - "args": ["/absolute/path/to/iexec-mcp-server/build/index.js"], + "args": ["/ABSOLUTE/PATH/TO-IEXEC-MCP-SERVER-REPO/build/index.js"], "env": { - "PRIVATE_KEY_PATH": "/absolute/path/to/wallet.json" + "PRIVATE_KEY_PATH": "/ABSOLUTE/PATH/TO/wallet.json" } } } @@ -183,7 +187,7 @@ npm run build "mcpServers": { "iexec-mcp-server": { "command": "node", - "args": ["/absolute/path/to/iexec-mcp-server/build/index.js"], + "args": ["/ABSOLUTE/PATH/TO-IEXEC-MCP-SERVER-REPO/build/index.js"], "env": { "PRIVATE_KEY": "0xYOUR_PRIVATE_KEY" } @@ -201,29 +205,11 @@ npm run build **Prerequisites:** - [Docker](https://www.docker.com/get-started) installed -- [Claude Desktop](https://claude.ai/download) (optional) - -**Setup Steps:** - -### 6.1. Run the Server with Docker - -_With wallet file (from Section 1):_ - -```bash -docker run -i --rm --init -e PRIVATE_KEY_PATH=/absolute/path/to/wallet.json iexec/mcp-server:latest -``` - -_With direct private key:_ - -```bash -docker run -i --rm --init -e PRIVATE_KEY=0xYOUR_PRIVATE_KEY iexec/mcp-server:latest -``` - -### 6.2. Integrate with Claude Desktop (Optional) +- [Claude Desktop](https://claude.ai/download) 1. **Open Claude Desktop configuration:** - - Open Claude Desktop → **Developer > Edit Config** +- Open Claude Desktop → **Developer > Edit Config** 2. **Add configuration to `claude_desktop_config.json`:** @@ -239,9 +225,11 @@ docker run -i --rm --init -e PRIVATE_KEY=0xYOUR_PRIVATE_KEY iexec/mcp-server:lat "-i", "--rm", "--init", + "-v", + "/ABSOLUTE/PATH/TO/YOUR/KEYSTORE:/app/keystore", "-e", - "PRIVATE_KEY_PATH=/absolute/path/to/wallet.json", - "iexec/mcp-server:latest" + "PRIVATE_KEY_PATH=/app/keystore/wallet.json", + "iexechub/mcp-server:latest" ] } } diff --git a/package-lock.json b/package-lock.json index 7cc2789..9502b03 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,11 +1,11 @@ { - "name": "@paypes/mcp-server", + "name": "@iexec/mcp-server", "version": "0.1.0-alpha.1", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "@paypes/mcp-server", + "name": "@iexec/mcp-server", "version": "0.1.0-alpha.1", "license": "MIT", "dependencies": { @@ -25,6 +25,10 @@ "@types/node": "^22.15.18", "dotenv": "^16.5.0", "typescript": "^5.8.3" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=9.0.0" } }, "node_modules/@adraffy/ens-normalize": { diff --git a/package.json b/package.json index 7a2b7b0..ab7318f 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,24 @@ { - "name": "@paypes/mcp-server", + "name": "@iexec/mcp-server", "version": "0.1.0-alpha.1", - "description": "MCP server for interacting with iExec Blockchain", + "description": "iExec MCP Server - Model Context Protocol server for iExec blockchain confidential computing", + "keywords": [ + "mcp", + "iExec", + "blockchain", + "confidential-computing", + "web3mail", + "dataprotector" + ], + "author": "iExec Team", + "homepage": "https://github.com/iExecBlockchainComputing/iexec-mcp-server", + "repository": { + "type": "git", + "url": "git+https://github.com/iExecBlockchainComputing/iexec-mcp-server.git" + }, + "bugs": { + "url": "https://github.com/iExecBlockchainComputing/iexec-mcp-server/issues" + }, "type": "module", "main": "build/index.js", "types": "build/index.d.ts", @@ -9,11 +26,6 @@ "mcp-server": "build/index.js", "run": "build/index.js" }, - "homepage": "https://github.com/iExecBlockchainComputing/iexec-mcp-server", - "repository": { - "type": "git", - "url": "git+https://github.com/iExecBlockchainComputing/iexec-mcp-server.git" - }, "files": [ "build", "README.md", @@ -26,6 +38,10 @@ "run": "node build/index.js", "inspector": "npx @modelcontextprotocol/inspector build/index.js" }, + "engines": { + "node": ">=18.0.0", + "npm": ">=9.0.0" + }, "license": "MIT", "dependencies": { "@iexec/dataprotector": "^2.0.0-beta.15", diff --git a/release-please-config.json b/release-please-config.json index 9a1436f..7f8013b 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -2,7 +2,7 @@ "packages": { ".": { "release-type": "node", - "package-name": "@paypes/mcp-server", + "package-name": "@iexec/mcp-server", "component": "", "changelog-sections": [ { "type": "feat", "section": "Features" },