Skip to content

[deferred] mc-detect 훅 마인크래프트 발견 시 Discord 웹훅 알림 전송 #149

Description

@whi02

출처

PR: #148 (mc-detect hookscript)
파일: backend/scripts/hooks/mc-detect-hook.sh:52 (# discord 웹훅으로 알림 기능 확장 주석)

내용

mc-detect-hook.sh는 마인크래프트 서버 발견 시 echo만 출력한다. 훅은 자동 실행이라 로그를 아무도 보지 않으므로, 발견 시 실제 알림 전송이 필요하다.

  • 발견 시 기존 Discord 웹훅으로 알림 전송 (main.py:587 _send_discord_message 참고, {"content": "..."} POST)
  • 메시지에 VMID 포함해 어느 VM인지 식별 가능하게
  • 호스트 bash의 웹훅 URL 획득 방법 결정 필요:
  • (a) 호스트 env 파일 + curl — 추천, git에 비밀값 미포함
  • (b) 백엔드 내부 엔드포인트 콜백
  • (c) 훅 주입 시 URL 전달

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions