Documentation
¶
Overview ¶
Package cache is a self-hosted GitHub Actions cache server implementing the v2 (twirp/JSON) CacheService protocol, so actions/cache stores blobs on this host instead of round-tripping to GitHub's Azure backend. The protocol and storage behavior are ported from falcondev-oss/github-actions-cache-server.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RunnerEnv ¶
RunnerEnv returns the environment variables to inject into each runner container so actions/cache (v2) targets this self-hosted server instead of GitHub's Azure backend. advertiseURL must be reachable from inside the container (e.g. http://host.docker.internal:3000).
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is the running cache HTTP server.
func (*Server) AdvertiseURL ¶
AdvertiseURL is the base URL runners should use to reach this cache.
func (*Server) RedactedAdvertiseURL ¶
RedactedAdvertiseURL is safe to log.
func (*Server) SetGitBundler ¶
func (s *Server) SetGitBundler(repoSlug string, f func(ctx context.Context, repoSlug string, w io.Writer) error)
SetGitBundler enables the dotgit-cache endpoint for one configured repository: GET /gitmirror/{owner}/{repo} streams a git bundle of that repo's host mirror.