Dockerfile / Dockerfile.fasttext
- Go entrypoint: replaced
entrypoint.shbash script with a statically-linked Go binary; removesbash,shadow,su-exec, andxmlstarletfrom the runtime image go_buildstage: added multi-stage build step that compiles the Go entrypoint binary (CGO_ENABLED=0) withGO_VERSIONARG tracked by Renovate7zipscope: moved fromjava_basetopreparestage — only needed at build time, not in the base layerHEALTHCHECK: replacedwget-based shell command withCMD ["/entrypoint", "healthcheck"]- User setup: replaced
groupmod/adduser(shadow) with BusyBoxaddgroup/adduser - Renovate annotations: corrected
datasource=github-release→github-releasesfor Temurin and Maven; added regex versioning for Temurin JDK tags
Go entrypoint (entrypoint/)
- New binary: replaces
entrypoint.sh; handles startup, privilege drop, ngram/fasttext downloads, and healthcheck with no shell dependency - UID/GID derivation: centralised into a single computation at startup (
MAP_UID/MAP_GIDenv vars when root,os.Getuid()/os.Getgid()otherwise) - Embedded download config: URLs and filenames extracted to
internal/download/downloads.yaml(embedded via//go:embed); no recompile needed to update URLs healthchecksubcommand: native HTTP check replacing thewget-basedHEALTHCHECKcommand- Read-only FS detection: replaced
/proc/mountsparsing withsyscall.StatfscheckingST_RDONLYflag - Ownership fix: uses mapped UID/GID when
nss_wrapperis active - Go upgraded to
1.26-alpine3.23 - Source tree: moved into
entrypoint/subfolder for cleaner repo layout