헬스 체크 설정
헬스 체크 엔드포인트와 Docker·Kubernetes 프로브 설정을 생성합니다
// Express
app.get('/health', (req, res) => res.status(200).json({ status: 'ok', uptime: process.uptime() }))
# Dockerfile
HEALTHCHECK --interval=30s --timeout=3s --retries=3 \
CMD wget -qO- http://localhost:3000/health || exit 1
# Kubernetes (container 안)
livenessProbe:
httpGet:
path: /health
port: 3000
periodSeconds: 30
readinessProbe:
httpGet:
path: /health
port: 3000
periodSeconds: 10
헬스 체크 설정 도구 소개
서비스 상태 확인을 위한 헬스 체크를 설정합니다 별도 설치나 회원가입 없이 브라우저에서 바로 사용할 수 있습니다.
관련 키워드: 헬스체크, 상태확인, 모니터링, 서비스