Documentation
¶
Overview ¶
Package pypi facilitates executing the program as a proxy server for translating pypi requests into OCI registry operations. This enables an OCI registry to act as a pypi package registry.
Index ¶
Constants ¶
View Source
const ( // PythonDistributionDigest is the annotation key used for denoting the digest (e.g., sha256:deedbef...) of the distribution file (often a whl). PythonDistributionDigest = "vnd.act3-ace.python.distribution.digest" // PythonDistributionFilename is the annotation key used for denoting the file name of the distribution file (often a mypkg-1.0.0-something.whl). PythonDistributionFilename = "vnd.act3-ace.python.distribution.filename" // PythonDistributionMetadataDigest is the annotation key used for denoting the digest of the METADATA of the whl or sdist. PythonDistributionMetadataDigest = "vnd.act3-ace.python.distribution.core-metadata.digest" // PythonDistributionVersion is the annotation key used for denoting the version of the distribution file (e.g., 1.2.3). PythonDistributionVersion = "vnd.act3-ace.python.distribution.version" // PythonDistributionRequiresPython is the annotation key used for denoting the requied python version to use the distribution file (e.g., >=3.7). PythonDistributionRequiresPython = "vnd.act3-ace.python.distribution.requires-python" // PythonDistributionProject is the annotation key used for denoting the project name of the distribution file (e.g., pyzmq). PythonDistributionProject = "vnd.act3-ace.python.distribution.project" // PythonDistributionYanked is the annotation key used for denoting that a distribution has been marked as yanked. The value is the reason. If this annotation is present with an empty value it means it is yanked but without a reason. PythonDistributionYanked = "vnd.act3-ace.python.distribution.yanked" // PythonSyncVersion is the annotation key used for denoting the sync software protocol/version used to create the manifest. PythonSyncVersion = "vnd.act3-ace.python.sync.version" )
View Source
const ( MediaTypePythonDistributionWheel = "applications/vnd.act3-ace.python.bdist.wheel+zip" MediaTypePythonDistributionSource = "applications/vnd.act3-ace.python.sdist.tar+gzip" MediaTypePythonDistributionEgg = "applications/vnd.act3-ace.python.bdist.egg+zip" MediaTypePythonDistributionUnknown = "applications/vnd.act3-ace.python.unknown" MediaTypePythonSourceDistribution = "applications/vnd.act3-ace.python.sdist.tar+gzip" MediaTypePythonDistributionMetadata = "application/vnd.act3-ace.python.core-metadata.v1" MediaTypePythonDistributionIndex = "application/vnd.act3-ace.python.index.v1+json" MediaTypePythonDistribution = "application/vnd.act3-ace.python.distribution.v1+json" )
MediaTypes for python artifacts.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Action ¶
type Action struct {
*actions.DataTool
// AllowYanked allows yanked packages to be mirrored
AllowYanked bool
}
Action represents a general pypi action.
type App ¶
type App struct {
// contains filtered or unexported fields
}
App implements the HTML web application.
type ToOCI ¶
type ToOCI struct {
*Action
// Selectors holds the python/abi/platform selectors
Selectors []string
// DryRun only figures what work it would do. It does not make any changes to OCI.
DryRun bool
// Reproducible removes timestamps.
Reproducible bool
// Clean will copy everything over assuming there is no existing OCI artifacts. When true, the prior files that were downloaded are ignored when constructing artifacts.
Clean bool
// IndexURL is the primary index URL
IndexURL string
// ExtraIndexURLs is a slice of extra index URLs to use to find packages. These are processed after IndexURL.
ExtraIndexURLs []string
// RequirementFile is a slice of requirement files to sync
RequirementFiles []string
// Also include the extra packages from requirements
IncludeExtras bool
// Continue even if an error occurs in processing a Python project or distribution.
// This is useful when combined with FailedRequirementsFile to collect the failures in a way that can be used to process the erroneous entries.
ContinueOnError bool
// FailedRequirementsPath is a file path to write the requirements that failed to be transferred
FailedRequirementsFile string
}
ToOCI represents the pypi to-oci action.
Click to show internal directories.
Click to hide internal directories.