Versions in this module Expand all Collapse all v0 v0.1.0 Jun 20, 2021 Changes in this version + type App interface + BaseURL func() *url.URL + Logger func() zerolog.Logger + NarinfoCache func() NarinfoCache + Storage func() storage.Storage + type Cache struct + func New(name string, cfg *Config, app App) (*Cache, error) + func (c *Cache) HandleCacheInfo(w http.ResponseWriter, r *http.Request) + func (c *Cache) HandleCacheNarinfo(w http.ResponseWriter, r *http.Request) + func (c *Cache) HandleCacheRead(w http.ResponseWriter, r *http.Request) + func (c *Cache) HandleUploadNar(w http.ResponseWriter, r *http.Request) + func (c *Cache) HandleUploadNarinfo(w http.ResponseWriter, r *http.Request) + func (c *Cache) Priority() int8 + type Config struct + Priority *int8 + PrivateKey PrivateKey + Public *bool + Substituters []ConfigSubstituter + type ConfigSubstituter struct + PublicKey PublicKey + URL string + type NarinfoCache interface + Get func(key string) ([]byte, error) + Set func(key string, entry []byte) error + type PrivateKey struct + Identifier string + func (c *PrivateKey) PublicKey() PublicKey + func (c *PrivateKey) UnmarshalYAML(value *yaml.Node) error + func (c PrivateKey) MarshalYAML() (interface{}, error) + type PublicKey struct + Identifier string + func (c *PublicKey) UnmarshalYAML(value *yaml.Node) error + func (c PublicKey) MarshalYAML() (interface{}, error) + func (c PublicKey) String() string