Documentation
¶
Index ¶
Constants ¶
View Source
const ( // PushedEventType is the cloudevents event type for APK pushes PushedEventType = "dev.chainguard.apk.push.v1" // PulledEventType is the cloudevents event type for APK pulls PulledEventType = "dev.chainguard.apk.pull.v1" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PullEvent ¶ added in v0.1.39
type PullEvent struct {
// Repository identifies the repository being pulled
Repository string `json:"repository"`
// RepoID identifies the UIDP of the APK repository (group) being pulled
RepoID string `json:"repo_id"`
// Package holds the name of the package being pushed.
Package string `json:"package"`
// Origin holds the name of the origin package being pushed. For
// subpackages, this is the name of the parent package, for main packages,
// this is the same as Package.
Origin string `json:"origin_package"`
// Version holds the version of the package being pushed.
Version string `json:"version"`
// Architecture holds the architecture of the package being pushed.
Architecture string `json:"architecture"`
// Checksum holds the checksum of the package's control section as
// it would appear in an APKINDEX entry for the package.
Checksum string `json:"checksum"`
// When holds when the pull occurred.
When civil.DateTime `json:"when"`
// Location holds the detected approximate location of the client who pulled.
// For example, "ColumbusOHUS" or "Minato City13JP".
Location string `json:"location"`
// RemoteAddress holds the address of the client who pulled.
RemoteAddress string `json:"remote_address"`
// UserAgent holds the user-agent of the client who pulled.
UserAgent string `json:"user_agent"`
// ProxyUIDP is the UIDP of the customer associated with the apkproxy pull, if any.
// This is only set if the pull was proxied through virtualapk.cgr.dev/<uidp>(/<hash>?)/original/<arch>/<pkg>.apk.
ProxyUIDP string `json:"proxy_uidp,omitempty"`
// ProxyHash is the hash of the image associated with the apkproxy pull, if any.
// This is only set if the pull was proxied through virtualapk.cgr.dev/<uidp>/<hash>/original/<arch>/<pkg>.apk.
ProxyHash string `json:"proxy_hash,omitempty"`
}
PullEvent describes an APK being pulled from the registry.
func (PullEvent) APKBasePath ¶ added in v0.1.39
APKBasePath is a convenience method for constructing the base path to the APK.
type PushEvent ¶
type PushEvent struct {
// Repository identifies the repository being pushed
Repository string `json:"repository"`
// RepoID identifies the UIDP of the APK repository (group) being pushed
RepoID string `json:"repo_id"`
// Package holds the name of the package being pushed.
Package string `json:"package"`
// Origin holds the name of the origin package being pushed. For
// subpackages, this is the name of the parent package, for main packages,
// this is the same as Package.
Origin string `json:"origin_package"`
// Version holds the version of the package being pushed.
Version string `json:"version"`
// Architecture holds the architecture of the package being pushed.
Architecture string `json:"architecture"`
// Checksum holds the checksum of the package's control section as
// it would appear in an APKINDEX entry for the package.
Checksum string `json:"checksum"`
// When holds when the push occurred.
When civil.DateTime `json:"when"`
// Location holds the detected approximate location of the client who pushed.
// For example, "ColumbusOHUS" or "Minato City13JP".
Location string `json:"location"`
// RemoteAddress holds the address of the client who pushed.
RemoteAddress string `json:"remote_address"`
// UserAgent holds the user-agent of the client who pushed.
UserAgent string `json:"user_agent"`
Error *Error `json:"error,omitempty"`
}
PushEvent describes an APK being pushed to the registry.
func (PushEvent) APKBasePath ¶ added in v0.1.26
APKBasePath is a convenience method for constructing the base path to the APK.
Click to show internal directories.
Click to hide internal directories.