Documentation
¶
Index ¶
- Constants
- Variables
- func CheckClientStatus(reqbody []byte) error
- func CleanCache(imageId string)
- func CopyImgLayer(srcPath, srcFile, dstPath, dstFile string, reqbody []byte) (int, error)
- func FillRespMsg(result bool, clientreason, serverreason string) models.CompleteMsg
- func GetAciPath(imageId, acifile string) string
- func GetImagePath(imageId string) string
- func GetManifestPath(imageId string) string
- func GetPubkeysPath(namespace, repository string) string
- func GetSignaturePath(imageId, signfile string) string
- func ParseManifest(data []byte) error
- func RemoteAddr(r *http.Request) string
- func Router() *mux.Router
- func RouterWithPrefix(prefix string) *mux.Router
- func VerifyAciSignature(acipath, signpath, pubkeyspath string) error
- type RouteDescriptor
- type URLBuilder
Constants ¶
View Source
const ( RouteNameBase = "base" RouteNameBlob = "blob" RouteNameManifest = "manifest" RouteNameTags = "tags" RouteNameBlobUpload = "blob-upload" RouteNameBlobUploadChunk = "blob-upload-chunk" )
Variables ¶
View Source
var DigestRegexp = regexp.MustCompile(`[a-zA-Z0-9-_+.]+:[a-fA-F0-9]+`)
View Source
var RepositoryNameComponentRegexp = regexp.MustCompile(`[a-z0-9]+(?:[._-][a-z0-9]+)*`)
View Source
var RepositoryNameRegexp = regexp.MustCompile(`(?:` + RepositoryNameComponentRegexp.String() + `/)*` + RepositoryNameComponentRegexp.String())
View Source
var TagNameRegexp = regexp.MustCompile(`[\w][\w.-]{0,127}`)
Functions ¶
func CheckClientStatus ¶
func CleanCache ¶
func CleanCache(imageId string)
func CopyImgLayer ¶
func FillRespMsg ¶
func FillRespMsg(result bool, clientreason, serverreason string) models.CompleteMsg
func GetAciPath ¶
func GetImagePath ¶
func GetManifestPath ¶
func GetPubkeysPath ¶
func GetSignaturePath ¶
func ParseManifest ¶
func RemoteAddr ¶
func RouterWithPrefix ¶
func VerifyAciSignature ¶
codes as below are implemented to support ACI storage
Types ¶
type RouteDescriptor ¶
type URLBuilder ¶
type URLBuilder struct {
// contains filtered or unexported fields
}
func NewURLBuilder ¶
func NewURLBuilder(root *url.URL) *URLBuilder
func NewURLBuilderFromRequest ¶
func NewURLBuilderFromRequest(r *http.Request) *URLBuilder
func (*URLBuilder) BuildBlobURL ¶
func (ub *URLBuilder) BuildBlobURL(name string, dgst string) (string, error)
func (*URLBuilder) BuildManifestURL ¶
func (ub *URLBuilder) BuildManifestURL(name, reference string) (string, error)
Click to show internal directories.
Click to hide internal directories.