feat: add multi-stage Dockerfile and docker-compose.yml

- Multi-stage Dockerfile: golang:1.24-alpine builder → alpine:3.21 runtime
  - CGO_ENABLED=0 for static binary, stripped with -ldflags="-s -w"
  - Only copies ca-certificates and tzdata to runtime image
  - Config via volume mount at /etc/gosearch/config.toml
- docker-compose.yml: gosearch + Valkey 8
  - Valkey healthcheck ensures gosearch starts after cache is ready
  - Persistent Valkey volume
  - config.toml mounted read-only
- Update .gitignore with Go build artifacts
This commit is contained in:
Franz Kafka 2026-03-21 15:46:33 +00:00
parent 94322ceff4
commit 4c54ed5b56
4 changed files with 70 additions and 0 deletions

10
.gitignore vendored
View file

@ -1 +1,11 @@
node_modules/
.agent/
*.exe
*.exe~
*.dll
*.so
*.dylib
*.test
*.out
gosearch
config.toml