Documentation ¶
Index ¶
- Variables
- func Blob(w http.ResponseWriter, r *http.Request, name string)
- func Error(w http.ResponseWriter, err error)
- type Storage
- func (s *Storage) BlobExists(ctx context.Context, name string) (v1.Descriptor, error)
- func (s *Storage) ServeIndex(w http.ResponseWriter, r *http.Request, idx v1.ImageIndex, also ...string) error
- func (s *Storage) ServeManifest(w http.ResponseWriter, r *http.Request, img v1.Image, also ...string) error
- func (s *Storage) WriteImage(ctx context.Context, img v1.Image, also ...string) error
- func (s *Storage) WriteObject(ctx context.Context, name, contents string) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotFound = errors.New("repository or commit not found")
Functions ¶
func Error ¶
func Error(w http.ResponseWriter, err error)
Types ¶
type Storage ¶
type Storage struct {
// contains filtered or unexported fields
}
func (*Storage) BlobExists ¶
func (*Storage) ServeIndex ¶
func (s *Storage) ServeIndex(w http.ResponseWriter, r *http.Request, idx v1.ImageIndex, also ...string) error
ServeIndex writes manifest, config and layer blobs for each image in the index, then writes and redirects to the index manifest contents pointing to those blobs.
func (*Storage) ServeManifest ¶
func (s *Storage) ServeManifest(w http.ResponseWriter, r *http.Request, img v1.Image, also ...string) error
ServeManifest writes config and layer blobs for the image, then writes and redirects to the image manifest contents pointing to those blobs.
func (*Storage) WriteImage ¶
WriteImage writes the layer blobs, config blob and manifest.
Click to show internal directories.
Click to hide internal directories.