Skip to main content
Glama
rsutana

rocks-db

by rsutana

설정 가이드: Fullscale Rocks MCP 서버

이 가이드는 fullscale-rocks 데이터베이스를 위한 MCP 서버를 설치, 구성 및 시작하는 방법을 설명합니다.

1. 설치

아직 설치하지 않았다면, 의존성을 설치하세요:

cd rocks-mcp
npm install

Related MCP server: DB MCP Server

2. 구성

서버는 데이터베이스 자격 증명과 OAuth 공개 키가 필요합니다.

데이터베이스 설정

rocks-mcp/.env 파일을 생성하거나 편집하세요:

MYSQL_HOST=127.0.0.1
MYSQL_PORT=3306
MYSQL_DATABASE=employee
MYSQL_USER=employee
MYSQL_PASSWORD=thisisapassword

PG_HOST=127.0.0.1
PG_PORT=5432
PG_DATABASE=employee
PG_USER=employee
PG_PASSWORD=thisisapassword

SSE_PORT=3001

인증

서버는 다음 경로에서 자동으로 OAuth 공개 키를 찾습니다: /home/ryscript/fullscale-rocks/rocks-api/storage/oauth-public.key

이 파일은 rocks-api에서 발행한 JWT 토큰을 검증하는 데 사용되므로 반드시 존재해야 합니다.

3. 서버 실행

개발 모드

tsx를 사용하여 서버를 실행합니다(파일 변경 시 자동 재로드):

npm run dev

프로덕션 모드

TypeScript 코드를 빌드하고 빌드된 버전을 시작합니다:

npm run build
npm start

4. AI 애플리케이션 연결

Claude Desktop

claude_desktop_config.json에 다음을 추가하세요:

{
  "mcpServers": {
    "rocks-db": {
      "command": "node",
      "args": ["/home/ryscript/fullscale-rocks/rocks-mcp/build/index.js"]
    }
  }
}

일반 MCP 클라이언트 (SSE)

서버는 원격 또는 웹 기반 클라이언트를 위한 서버 전송 이벤트(SSE)도 지원합니다.

  • SSE URL: http://localhost:3001/sse

  • Post Message URL: http://localhost:3001/message

MCP Inspector 또는 기타 SSE 호환 클라이언트와 함께 사용할 수 있습니다.

5. 도구 참조

서버는 다음과 같은 도구를 제공합니다:

도구

목적

요구 사항

execute_read

SELECT 쿼리 실행

auth_token, db_type

execute_write

INSERT/UPDATE/DELETE 실행

auth_token (관리자 전용), db_type

list_tables

모든 테이블 목록 조회

auth_token, db_type

describe_table

테이블의 컬럼 정보 표시

auth_token, db_type, table_name


참고: auth_token은 rocks-api 로그인 프로세스를 통해 획득한 유효한 Bearer 토큰이어야 합니다.

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables secure interaction with MySQL databases through SQL queries, supporting read-only operations without approval and write operations with user confirmation.
    6 npm
    ISC
  • A
    license
    A
    quality
    D
    maintenance
    Enables executing SQL queries, schema introspection, and data management for PostgreSQL and MySQL databases via natural language, supporting local, SSH, and AWS RDS connections.
    8
    145 npm
    MIT
  • F
    license
    A
    quality
    D
    maintenance
    Enables read-only exploration and querying of PostgreSQL or MySQL databases via MCP, with schema discovery, safe SQL validation, natural language to SQL conversion, and CSV export.
    11
    1
    -
  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables secure SQL query execution on MySQL databases with authentication and permission control, allowing users to explore database tables and run read-only queries.
    -