feat(server): Cache built manifests to the GCS bucket

Caches manifests under `manifests/$cacheKey` in the GCS bucket and
introduces two-tiered retrieval of manifests from the caches (local
first, bucket second).

There is some cleanup to be done in this code, but the initial version
works.
This commit is contained in:
Vincent Ambo 2019-09-09 16:41:52 +01:00 committed by Vincent Ambo
parent 051eb77b3d
commit 4a58b0ab4d
3 changed files with 97 additions and 24 deletions

View file

@ -125,7 +125,7 @@ type registryHandler struct {
cfg *config.Config
ctx *context.Context
bucket *storage.BucketHandle
cache *builder.BuildCache
cache *builder.LocalCache
}
func (h *registryHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {