Skip to content

chore(monitoring): Prometheus 보관 기간 15d → 90d - #77

Merged
weeast1521 merged 1 commit into
mainfrom
chore/prometheus-retention-90d
Oct 23, 2026
Merged

weeast1521 merged 1 commit into
mainfrom
chore/prometheus-retention-90d

Conversation

@weeast1521

Copy link
Copy Markdown
Owner

왜

운영 지표(동시 접속자 active_users, 요청 수, 응답 시간)가 Prometheus 기본 보관 15일이 지나면 사라진다. 대회 기간 기록을 끝난 뒤에도 돌아볼 수 있게 90일로 늘린다.

무엇

  • docker-compose.prod.yml prometheus 서비스에 command: 추가 — --storage.tsdb.retention.time=90d
    • command:는 이미지 기본 CMD를 통째로 대체하므로 --config.file·--storage.tsdb.path를 함께 명시
  • docs/INFRA.md Phase 3에 "10-23 3차" 항목 기록

적용 (머지 후 VM에서, 배포 스크립트는 prometheus를 건드리지 않음)

cd /opt/applegame && git pull
docker compose -f docker-compose.prod.yml up -d prometheus
docker exec apple-prometheus wget -qO- localhost:9090/api/v1/status/flags | grep -o '"storage.tsdb.retention.time":"[^"]*"'

기존 prometheus-data 볼륨은 그대로 쓰므로 지금까지 쌓인 데이터는 유지된다.

용량

이 규모(수천 시계열, 15s 수집)면 하루 수십 MB. 90일이어도 수 GB 안.

🤖 Generated with Claude Code

대회 기간의 동시 접속자·요청 지표를 끝난 뒤에도 돌아볼 수 있게 retention을 늘린다.
compose에 command를 주면 이미지 기본 CMD가 통째로 대체되므로 --config.file·--storage.tsdb.path를 함께 적는다.
VM 적용: docker compose -f docker-compose.prod.yml up -d prometheus (기존 데이터 유지).

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@weeast1521
weeast1521 merged commit d4c6a88 into main Oct 23, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant