registry

package
v0.0.0-...-0cfc503 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 12, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package registry implements a docker V2 registry and the OCI distribution specification.

It is designed to be used anywhere a low dependency container registry is needed, with an initial focus on tests.

Its goal is to be standards compliant and its strictness will increase over time.

Example
package main

import (
	"fmt"
	"net/http/httptest"

	"github.com/flant/go-containerregistry/pkg/registry"
)

func main() {
	s := httptest.NewServer(registry.New())
	defer s.Close()
	resp, _ := s.Client().Get(s.URL + "/v2/bar/blobs/sha256:...")
	fmt.Println(resp.StatusCode)
}
Output:

404

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() http.Handler

New returns a handler which implements the docker registry protocol. It should be registered at the site root.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL