MCP Sumo Logic Server

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

Integrations

  • Provides containerization support for easy deployment of the MCP server in Docker environments with configuration through environment variables.

  • Enables searching and querying of Sumo Logic logs using custom queries with configurable time ranges, allowing access to log data stored in Sumo Logic's platform.

MCP 스모 로직

Sumo Logic의 API와 통합되어 로그 검색을 수행하는 MCP(Model Context Protocol) 서버입니다.

특징

  • 사용자 정의 쿼리를 사용하여 Sumo Logic 로그 검색
  • 검색을 위한 구성 가능한 시간 범위
  • 오류 처리 및 자세한 로깅
  • 간편한 배포를 위한 Docker 지원

환경 변수

지엑스피1

설정

  1. 저장소를 복제합니다
  2. 종속성 설치:
    npm install
  3. 필요한 환경 변수로 .env 파일을 만듭니다.
  4. 프로젝트를 빌드하세요:
    npm run build
  5. 서버를 시작합니다:
    npm start

도커 설정

  1. Docker 이미지를 빌드합니다.
    docker build -t mcp/sumologic .
  2. 컨테이너를 실행합니다(방법 하나 선택):a. 환경 변수를 직접 사용하는 경우:
    docker run -e ENDPOINT=your_endpoint -e SUMO_API_ID=your_api_id -e SUMO_API_KEY=your_api_key mcp/sumologic
    b. .env 파일 사용:
    docker run --env-file .env mcp/sumologic
    참고: .env 파일에 필수 환경 변수가 포함되어 있는지 확인하세요.
    ENDPOINT=your_endpoint SUMO_API_ID=your_api_id SUMO_API_KEY=your_api_key

용법

서버는 다음 매개변수를 허용하는 search-sumologic 도구를 제공합니다.

  • query (필수): Sumo Logic 검색 쿼리
  • (선택 from ): ISO 8601 형식의 시작 시간
  • (선택 to ): ISO 8601 형식의 종료 시간

예제 쿼리:

const query = '_index=app_pro_fiat_cont | json auto | fields log_identifier'; const results = await search(sumoClient, query, { from: '2024-02-23T00:00:00Z', to: '2024-02-24T00:00:00Z', });

오류 처리

서버에는 포괄적인 오류 처리 및 로깅이 포함되어 있습니다.

  • API 오류가 발견되어 세부 정보와 함께 기록됩니다.
  • 검색 작업 상태가 모니터링되고 기록됩니다.
  • 네트워크 및 인증 문제가 적절하게 처리됩니다.

개발

개발 모드에서 실행하려면:

npm run dev

테스트용:

npm test
-
security - not tested
F
license - not found
-
quality - not tested

Sumo Logic의 API와 통합되어 구성 가능한 쿼리와 시간 범위로 로그를 검색할 수 있으며, Docker를 통한 오류 처리와 간편한 배포를 지원합니다.

  1. Features
    1. Environment Variables
      1. Setup
        1. Docker Setup
          1. Usage
            1. Error Handling
              1. Development
                ID: 6vnt6vueaf