29e4777eec
Private Go modules have nowhere to live: goproxy is remote-only, so internal modules need VCS access or a hand-rolled proxy. - serve local goproxy repos over the GOPROXY protocol (`@v/list`, `@latest`, `.info`/`.mod`/`.zip`) with case-encoded module paths - accept PUT uploads of `.zip`/`.mod`/`.info` per version; synthesize `.info` when absent - validate zips with `golang.org/x/mod/zip.CheckZip`, `.mod` module path and `.info` version before storing - add a ContentValidator hook so providers can check upload bytes - document publishing in the UI and `docs/goproxy/local.md`; add an e2e-docker case Reviewed-on: #143 Co-authored-by: unkin-agent <unkin-agent@unkin.net> Co-committed-by: unkin-agent <unkin-agent@unkin.net>
7 lines
197 B
Go
7 lines
197 B
Go
package provider
|
|
|
|
// ContentValidator checks an upload's bytes (spooled to localFile) before it is stored.
|
|
type ContentValidator interface {
|
|
ValidateContent(storagePath, localFile string) error
|
|
}
|