|
@@ -33,6 +33,10 @@ This MCP server provides tools to:
|
|
|
- A Gogs server instance
|
|
- A Gogs server instance
|
|
|
- Gogs access token (optional, but recommended for authenticated access)
|
|
- Gogs access token (optional, but recommended for authenticated access)
|
|
|
|
|
|
|
|
|
|
+**OR**
|
|
|
|
|
+
|
|
|
|
|
+- Docker and Docker Compose (for containerized deployment)
|
|
|
|
|
+
|
|
|
### Setup
|
|
### Setup
|
|
|
|
|
|
|
|
1. Clone this repository:
|
|
1. Clone this repository:
|
|
@@ -51,6 +55,36 @@ This MCP server provides tools to:
|
|
|
npm run build
|
|
npm run build
|
|
|
```
|
|
```
|
|
|
|
|
|
|
|
|
|
+### Docker Setup
|
|
|
|
|
+
|
|
|
|
|
+1. Clone this repository:
|
|
|
|
|
+ ```bash
|
|
|
|
|
+ git clone ssh://git@207.154.220.231:10022/claude/gogs-mcp.git
|
|
|
|
|
+ cd gogs-mcp
|
|
|
|
|
+ ```
|
|
|
|
|
+
|
|
|
|
|
+2. Create a `.env` file from the example:
|
|
|
|
|
+ ```bash
|
|
|
|
|
+ cp .env.example .env
|
|
|
|
|
+ ```
|
|
|
|
|
+
|
|
|
|
|
+3. Edit `.env` and configure your Gogs server URL and access token:
|
|
|
|
|
+ ```bash
|
|
|
|
|
+ GOGS_SERVER_URL=https://your-gogs-server.com
|
|
|
|
|
+ GOGS_ACCESS_TOKEN=your-access-token-here
|
|
|
|
|
+ ```
|
|
|
|
|
+
|
|
|
|
|
+4. Build and run with Docker Compose:
|
|
|
|
|
+ ```bash
|
|
|
|
|
+ docker-compose up -d
|
|
|
|
|
+ ```
|
|
|
|
|
+
|
|
|
|
|
+ Or build the Docker image manually:
|
|
|
|
|
+ ```bash
|
|
|
|
|
+ docker build -t gogs-mcp-server .
|
|
|
|
|
+ docker run --env-file .env gogs-mcp-server
|
|
|
|
|
+ ```
|
|
|
|
|
+
|
|
|
## Configuration
|
|
## Configuration
|
|
|
|
|
|
|
|
### Generate Gogs Access Token
|
|
### Generate Gogs Access Token
|
|
@@ -111,6 +145,46 @@ export GOGS_ACCESS_TOKEN=your-access-token-here
|
|
|
npm start
|
|
npm start
|
|
|
```
|
|
```
|
|
|
|
|
|
|
|
|
|
+### With Docker
|
|
|
|
|
+
|
|
|
|
|
+You can use the Docker image with MCP clients by mounting it as a command:
|
|
|
|
|
+
|
|
|
|
|
+```json
|
|
|
|
|
+{
|
|
|
|
|
+ "mcpServers": {
|
|
|
|
|
+ "gogs": {
|
|
|
|
|
+ "command": "docker",
|
|
|
|
|
+ "args": [
|
|
|
|
|
+ "run",
|
|
|
|
|
+ "--rm",
|
|
|
|
|
+ "-i",
|
|
|
|
|
+ "-e", "GOGS_SERVER_URL=https://your-gogs-server.com",
|
|
|
|
|
+ "-e", "GOGS_ACCESS_TOKEN=your-access-token-here",
|
|
|
|
|
+ "gogs-mcp-server:latest"
|
|
|
|
|
+ ]
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+}
|
|
|
|
|
+```
|
|
|
|
|
+
|
|
|
|
|
+Or using docker-compose:
|
|
|
|
|
+
|
|
|
|
|
+```json
|
|
|
|
|
+{
|
|
|
|
|
+ "mcpServers": {
|
|
|
|
|
+ "gogs": {
|
|
|
|
|
+ "command": "docker-compose",
|
|
|
|
|
+ "args": [
|
|
|
|
|
+ "-f", "/absolute/path/to/gogs-mcp-server/docker-compose.yml",
|
|
|
|
|
+ "run",
|
|
|
|
|
+ "--rm",
|
|
|
|
|
+ "gogs-mcp-server"
|
|
|
|
|
+ ]
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+}
|
|
|
|
|
+```
|
|
|
|
|
+
|
|
|
## Available Tools
|
|
## Available Tools
|
|
|
|
|
|
|
|
### User Tools
|
|
### User Tools
|