{"modulePath":"github.com/GoCodeAlone/workflow","version":"v0.87.0","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package registrygitlab\n\nPackage registrygitlab provides the GitLab Container Registry provider.\n\n## Functions\n\n```go\nfunc AuthHeaderFor(tokenType string) string\n```\nAuthHeaderFor returns the correct GitLab API auth header name for tokenType. Exported for testing. tokenType is \"job\" (CI\\_JOB\\_TOKEN) or \"private\" (PAT/oauth2).\n\n```go\nfunc New() registry.RegistryProvider\n```\nNew returns a new GitLabProvider.\n\n## Types\n\n```go\ntype GitLabProvider struct{}\n```\nGitLabProvider implements registry.RegistryProvider for GitLab Container Registry.\n\n```go\nfunc (g *GitLabProvider) Login(ctx registry.Context, cfg registry.ProviderConfig) error\n```\nLogin authenticates with the GitLab registry host. In CI context ($CI\\_JOB\\_TOKEN set), uses gitlab-ci-token as username. Otherwise uses oauth2 with the token from auth.env.\n\n```go\nfunc (g *GitLabProvider) Logout(ctx registry.Context, cfg registry.ProviderConfig) error\n```\n\n```go\nfunc (g *GitLabProvider) Name() string\n```\n\n```go\nfunc (g *GitLabProvider) Prune(ctx registry.Context, cfg registry.ProviderConfig) error\n```\nPrune deletes tags beyond retention.keep\\_latest via the GitLab Container Registry API. Supports self-managed instances via ci.registries\\[].api\\_base\\_url.\n\n```go\nfunc (g *GitLabProvider) Push(ctx registry.Context, cfg registry.ProviderConfig, imageRef string) error\n```\n\n","path":"github.com/GoCodeAlone/workflow/plugins/registry-gitlab","name":"registrygitlab","synopsis":"Package registrygitlab provides the GitLab Container Registry provider.","isRedistributable":true}
