Skip to main content

Deployment: hbf-data-retention

Infrastructure config for this service. Full platform deployment: docs/architecture/deployment.md

Runtime

  • Port: configurable via SERVICE_PORT (default: 3004 per .env)
  • Base image: node:22-slim (multi-stage)
  • Start command: npm run start:prod
  • Health check: none defined

Required Environment Variables

VariableExampleDescription
HBF_CORE_URLhttp://hbf-core:8080Core service base URL
HBF_CORE_ACCESS_TOKENAuth token for core service
EXECUTION_INTERVAL_IN_HOURS6Polling interval for cleanup runs
THRESHOLD_OF_DELETION_RETIRES1Max retries before skipping a deletion
SERVICE_PORT3004HTTP listen port
AWS_REGIONAWS region (required)
AWS_ACCESS_KEYAWS access key (required)
AWS_SECRET_ACCESS_KEYAWS secret key (required)
AWS_S3_BUCKET_NAMES3 bucket name (required)
MINIO_ENDPOINTOptional MinIO endpoint URL
S3_FORCE_PATH_STYLEForce path-style S3 URLs (for MinIO, true/false)
PINO_LOGGER_USEtrueEnable pino logger
PINO_LOGGER_LEVELdebugLog level
PINO_LOGGER_AUTO_LOGGINGfalseAuto-log requests
ELASTIC_APM_ACTIVEfalseEnable Elastic APM agent
ELASTIC_APM_SERVER_URLAPM server URL
ELASTIC_APM_SECRET_TOKENAPM secret token
ELASTIC_APM_SERVICE_NAMEhbf-data-retentionAPM service name
ELASTIC_APM_ENVIRONMENTlocalAPM environment

Docker

# Build
docker build -t hbf-data-retention .

# Run (local dev)
docker compose up

docker-compose runs the service only (no ports mapped, no sidecar dependencies).

CI/CD

  • Trigger: push to main/staging/develop
  • Steps: SonarQube audit -> Docker build -> Push to ECR -> Deploy to EKS
  • Deploy target: AWS EKS (helvia-dev, helvia-stg, helvia)

Notes

  • Polling daemon with no HTTP endpoints. Runs periodic GDPR data cleanup against hbf-core.