Single stateless Go process that consumes CT logs via embedded (patched) CertSpotter internals, classifies cloud/database/storage DNS identifiers in-process with a zero-allocation classifier, enriches via round-robin DNS resolvers with CNAME following, and batch-writes useful findings to PostgreSQL. - third_party/certspotter: 2-hunk IdentifierSink patch, no stdout/JSON/files - internal/classify: AWS/Azure/GCP/Firebase/Cloudflare R2/DigitalOcean/Supabase/OCI - internal/dns: sharded bounded TTL cache, multi-resolver load balancing + failover - internal/pipeline: bounded queues, dedup, direct-priority load shedding - internal/store: pgx batch writer, Postgres CT checkpoints (no cert contents) - internal/probe: optional non-destructive reachability checks (off by default) - Docker: distroless non-root, read-only rootfs, no app volume, resource limits - tests enforce 0 allocs/op on the classifier and sink hot path
22 lines
427 B
Go
22 lines
427 B
Go
// Package migrations embeds the SQL schema so no runtime filesystem access is
|
|
// required.
|
|
package migrations
|
|
|
|
import "embed"
|
|
|
|
//go:embed *.sql
|
|
var FS embed.FS
|
|
|
|
// SQL returns the migration files in lexical order.
|
|
func SQL() []string {
|
|
entries, err := FS.ReadDir(".")
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
names := make([]string, 0, len(entries))
|
|
for _, e := range entries {
|
|
names = append(names, e.Name())
|
|
}
|
|
return names
|
|
}
|