registrybackend

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2019 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Copyright (c) 2016-2019 Uber Technologies, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright (c) 2016-2019 Uber Technologies, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright (c) 2016-2019 Uber Technologies, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlobClient

type BlobClient struct {
	// contains filtered or unexported fields
}

BlobClient stats and downloads blob from registry.

func NewBlobClient

func NewBlobClient(config Config) (*BlobClient, error)

NewBlobClient creates a new BlobClient.

func (*BlobClient) Download

func (c *BlobClient) Download(namespace, name string, dst io.Writer) error

Download gets a blob from registry.

func (*BlobClient) List

func (c *BlobClient) List(prefix string, opts ...backend.ListOption) (*backend.ListResult, error)

List is not supported for blobs.

func (*BlobClient) Stat

func (c *BlobClient) Stat(namespace, name string) (*core.BlobInfo, error)

Stat sends a HEAD request to registry for a blob and returns the blob size.

func (*BlobClient) Upload

func (c *BlobClient) Upload(namespace, name string, src io.Reader) error

Upload is not supported as users can push directly to registry.

type Config

type Config struct {
	Address  string          `yaml:"address"`
	Security security.Config `yaml:"security"`
}

Config defines the registry address and security options.

type TagClient

type TagClient struct {
	// contains filtered or unexported fields
}

TagClient stats and downloads tag from registry.

func NewTagClient

func NewTagClient(config Config) (*TagClient, error)

NewTagClient creates a new TagClient.

func (*TagClient) Download

func (c *TagClient) Download(namespace, name string, dst io.Writer) error

Download gets the digest for a tag from registry.

func (*TagClient) List

func (c *TagClient) List(prefix string, opts ...backend.ListOption) (*backend.ListResult, error)

List is not supported as users can list directly from registry.

func (*TagClient) Stat

func (c *TagClient) Stat(namespace, name string) (*core.BlobInfo, error)

Stat sends a HEAD request to registry for a tag and returns the manifest size.

func (*TagClient) Upload

func (c *TagClient) Upload(namespace, name string, src io.Reader) error

Upload is not supported as users can push directly to registry.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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