ocireg

package
v0.13.0 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

README

Repository OCIRegistry and ociRegistry - OCI Registry based OCM Repositories

Synopsis
type: OCIRegistry/v1
Description

The content of the OCM repository will be stored in an OCI registry using a dedicated OCI repository name prefix.

Supported specification version is v1.

Specification Versions
Version v1

The type specific specification fields are:

  • baseUrl string

    OCI registry reference, containing the registry host URL. docker.io cannot be used to host an OCM repository because it provides a fixed number of levels for repository names (2).

  • subPath (optional) string

    the OCI repository prefix used for the OCM repository.

  • componentNameMapping (optional) string (deprecated)

    the mapping algorithm used to map OCM component names to OCU repository names ( urlPath (default) or sha256-digest).

Go Bindings

The Go binding can be found here.

Documentation

Index

Constants

View Source
const (
	Type   = ocireg.Type
	TypeV1 = ocireg.TypeV1

	OCIRegistryURLPathMapping ComponentNameMapping = "urlPath"
	OCIRegistryDigestMapping  ComponentNameMapping = "sha256-digest"
)

Variables

This section is empty.

Functions

func NewRepository added in v0.5.0

func NewRepository(ctx cpi.ContextProvider, baseURL string, metas ...*ComponentRepositoryMeta) (cpi.Repository, error)

func Normalize added in v0.9.0

func Normalize(s *genericocireg.RepositorySpec)

Types

type ComponentNameMapping

type ComponentNameMapping = genericocireg.ComponentNameMapping

ComponentNameMapping describes the method that is used to map the "Component Name", "Component Version"-tuples to OCI Image References.

type ComponentRepositoryMeta

type ComponentRepositoryMeta = genericocireg.ComponentRepositoryMeta

ComponentRepositoryMeta describes config special for a mapping of a component repository to an oci registry.

func NewComponentRepositoryMeta

func NewComponentRepositoryMeta(subPath string, mapping ...ComponentNameMapping) *ComponentRepositoryMeta

type RepositorySpec

type RepositorySpec = genericocireg.RepositorySpec

RepositorySpec describes a component repository backed by a oci registry.

func NewRepositorySpec

func NewRepositorySpec(baseURL string, metas ...*ComponentRepositoryMeta) *RepositorySpec

NewRepositorySpec creates a new RepositorySpec. If no ocm meta is given, the subPath part is extracted from the base URL. Otherwise, the given URL is used as OCI registry URL as it is.

Jump to

Keyboard shortcuts

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