Documentation ¶
Index ¶
- Constants
- func BulkDelete(p *platform.Platform, concurrency int, file string, expectedCount int) error
- func CheckManifest(p *platform.Platform, image string) error
- func Defaults(p *types.PlatformConfig)
- func Deploy(p *platform.Platform) error
- func IntegrityCheck(p *platform.Platform, concurrency int) (chan Tag, error)
- func IntegrityCheckFromFile(p *platform.Platform, concurrency int, file string) (chan Tag, error)
- func ListImages(p *platform.Platform, concurrency int) (chan Image, error)
- func ListImagesWithTags(p *platform.Platform, concurrency int) (chan Tag, error)
- func ReplicateAll(p *platform.Platform) error
- func Test(p *platform.Platform, test *console.TestResults)
- func UpdateSettings(p *platform.Platform) error
- type Artifact
- type ArtifactTag
- type Client
- func (harbor *Client) GetStatus() (*Status, error)
- func (harbor *Client) ListMembers(project string) ([]ProjectMember, error)
- func (harbor *Client) ListReplicationPolicies() (policies []ReplicationPolicy, customErr error)
- func (harbor *Client) TriggerReplication(id int) (*Replication, error)
- func (harbor *Client) UpdateSettings(settings types.HarborSettings) error
- type Error
- type ErrorResponse
- type Image
- type IngressClient
- func (harbor *IngressClient) DeleteTag(tag Tag) error
- func (harbor *IngressClient) GetManifest(project, image, tag string) (*Manifest, error)
- func (harbor *IngressClient) ListArtifacts(project string, image string) ([]Artifact, error)
- func (harbor *IngressClient) ListImages(project string) ([]Image, error)
- func (harbor *IngressClient) ListProjects() ([]Project, error)
- type IntegrityCheckFile
- type Manifest
- type ManifestLayer
- type Project
- type ProjectMember
- type Replication
- type ReplicationFilter
- type ReplicationPolicy
- type ReplicationRegistry
- type ReplicationTrigger
- type Status
- type Tag
Constants ¶
View Source
const (
HaborRegistryUsername = "harbor_registry_user"
)
View Source
const Namespace = "harbor"
Variables ¶
This section is empty.
Functions ¶
func BulkDelete ¶ added in v0.21.3
func Defaults ¶
func Defaults(p *types.PlatformConfig)
func IntegrityCheck ¶ added in v0.21.1
func IntegrityCheckFromFile ¶ added in v0.21.1
func ListImages ¶ added in v0.21.1
func ListImagesWithTags ¶ added in v0.21.1
func ReplicateAll ¶
func UpdateSettings ¶
Types ¶
type Artifact ¶ added in v0.21.1
type Artifact struct { ID int `json:"id,omitempty"` Type string `json:"type,omitempty"` MediaType string `json:"media_type,omitempty"` ManifestMediaType string `json:"manifest_media_type,omitempty"` ProjectID int `json:"project_id,omitempty"` RepositoryID int `json:"repository_id,omitempty"` Digest string `json:"digest,omitempty"` Size int `json:"size,omitempty"` Tags []ArtifactTag `json:"tags"` }
type ArtifactTag ¶ added in v0.21.1
type ArtifactTag struct {
Name string `json:"name"`
}
type Client ¶
func (*Client) ListMembers ¶
func (harbor *Client) ListMembers(project string) ([]ProjectMember, error)
func (*Client) ListReplicationPolicies ¶
func (harbor *Client) ListReplicationPolicies() (policies []ReplicationPolicy, customErr error)
func (*Client) TriggerReplication ¶
func (harbor *Client) TriggerReplication(id int) (*Replication, error)
func (*Client) UpdateSettings ¶
func (harbor *Client) UpdateSettings(settings types.HarborSettings) error
type ErrorResponse ¶ added in v0.21.1
type ErrorResponse struct {
Errors []Error `json:"errors"`
}
func (*ErrorResponse) String ¶ added in v0.21.1
func (e *ErrorResponse) String() string
type Image ¶ added in v0.21.1
type Image struct { ID int `json:"id,omitempty"` ProjectID int `json:"project_id,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` ArtifactCount int `json:"artifact_count,omitempty"` PullCount int `json:"pull_count,omitempty"` ProjectName string `json:"-"` }
type IngressClient ¶ added in v0.21.1
func NewIngressClient ¶ added in v0.21.1
func NewIngressClient(p *platform.Platform) (*IngressClient, error)
NewIngressClient creates a new harbor client using the harbor ingress
func (*IngressClient) DeleteTag ¶ added in v0.21.3
func (harbor *IngressClient) DeleteTag(tag Tag) error
func (*IngressClient) GetManifest ¶ added in v0.21.1
func (harbor *IngressClient) GetManifest(project, image, tag string) (*Manifest, error)
func (*IngressClient) ListArtifacts ¶ added in v0.21.1
func (harbor *IngressClient) ListArtifacts(project string, image string) ([]Artifact, error)
func (*IngressClient) ListImages ¶ added in v0.21.1
func (harbor *IngressClient) ListImages(project string) ([]Image, error)
func (*IngressClient) ListProjects ¶ added in v0.21.1
func (harbor *IngressClient) ListProjects() ([]Project, error)
type IntegrityCheckFile ¶ added in v0.21.3
type Manifest ¶ added in v0.21.1
type Manifest struct { SchemaVersion int `json:"schemaVersion"` MediaType string `json:"mediaType"` Config ManifestLayer `json:"config"` Layers []ManifestLayer `json:"layers"` }
type ManifestLayer ¶ added in v0.21.1
type ProjectMember ¶
type ProjectMember struct { ID int `json:"id,omitempty"` ProjectID int `json:"project_id,omitempty"` EntityName string `json:"entity_name,omitempty"` RoleName string `json:"role_name,omitempty"` RoleID int `json:"role_id,omitempty"` EntityID int `json:"entity_id,omitempty"` EntityType string `json:"entity_type,omitempty"` }
type Replication ¶
type Replication struct { ID int `json:"id,omitempty"` PolicyID int `json:"policy_id,omitempty"` Status string `json:"status,omitempty"` StatusText string `json:"status_text,omitempty"` Trigger string `json:"trigger,omitempty"` Total int `json:"total,omitempty"` Failed int `json:"failed,omitempty"` Succeed int `json:"succeed,omitempty"` InProgress int `json:"in_progress,omitempty"` Stopped int `json:"stopped,omitempty"` StartTime string `json:"start_time,omitempty"` EndTime string `json:"end_time,omitempty"` }
type ReplicationFilter ¶
type ReplicationPolicy ¶
type ReplicationPolicy struct { ID int `json:"id,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` SrcRegistry ReplicationRegistry `json:"src_registry,omitempty"` DestRegistry ReplicationRegistry `json:"dest_registry,omitempty"` DestNamespace string `json:"dest_namespace,omitempty"` Trigger ReplicationTrigger `json:"trigger,omitempty"` Filters []ReplicationFilter `json:"filters,omitempty"` Deletion bool `json:"deletion,omitempty"` Override bool `json:"override,omitempty"` Enabled bool `json:"enabled,omitempty"` CreationTime string `json:"creation_time,omitempty"` UpdateTime string `json:"update_time,omitempty"` }
type ReplicationRegistry ¶
type ReplicationRegistry struct { ID int `json:"id,omitempty"` URL string `json:"url,omitempty"` Name string `json:"name,omitempty"` Credential struct { Type string `json:"type,omitempty"` AccessKey string `json:"access_key,omitempty"` AccessSecret string `json:"access_secret,omitempty"` } `json:"credential,omitempty"` Type string `json:"type,omitempty"` Insecure bool `json:"insecure,omitempty"` Description string `json:"description,omitempty"` Status string `json:"status,omitempty"` CreationTime string `json:"creation_time,omitempty"` UpdateTime string `json:"update_time,omitempty"` }
type ReplicationTrigger ¶
Click to show internal directories.
Click to hide internal directories.