- dns.TTLCache: stop preallocating every shard map to maxShard; this allocated the full theoretical cache capacity up front (hundreds of MB of empty buckets) and pushed the container over its memory limit, causing an OOM restart loop under Docker's default 1g cap. - pipeline: write direct provider matches immediately without a blocking DNS enrichment step, so they can no longer be starved by the optional CNAME queue. Add TestDirectNotStarvedByDNSBacklog. - config: add DEDUP_SIZE, lower DNS_CACHE_SIZE/DEDUP_SIZE defaults to 256k. - .env.example / README: document DEDUP_SIZE and cache sizing. Live: stable at ~250-300 MiB with no restarts, direct queue draining to 0.
19 lines
538 B
Bash
19 lines
538 B
Bash
# Copy to .env and edit. .env is gitignored.
|
|
|
|
POSTGRES_USER=ctcloud
|
|
POSTGRES_PASSWORD=change-me-strong
|
|
POSTGRES_DB=ctcloud
|
|
|
|
# Local compose (private bridge network, no TLS):
|
|
DATABASE_URL=postgres://ctcloud:change-me-strong@postgres:5432/ctcloud?sslmode=disable
|
|
|
|
# Production: use a TLS-enabled database instead, e.g.
|
|
# DATABASE_URL=postgres://user:[email protected]:5432/ctcloud?sslmode=verify-full
|
|
|
|
DNS_SERVERS=1.1.1.1:53,8.8.8.8:53,1.0.0.1:53
|
|
DNS_WORKERS=16
|
|
DNS_CACHE_SIZE=262144
|
|
DEDUP_SIZE=262144
|
|
LOG_LEVEL=info
|
|
ACTIVE_PROBING=false
|