registrycreds

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package registrycreds 는 스택이 설치한 레지스트리의 자격증명을 푼다.

스택이 Harbor·Nexus 를 직접 설치하면 그 관리자 자격증명은 설치 과정 (provisioning_secrets)이 OpenBao 에 만들어 둔다. 플랫폼이 이미 갖고 있는 값을 사용자에게 다시 받아 적게 할 이유가 없다 — 화면은 묻지도 않으므로, 받지 못하면 HARBOR_USERNAME/HARBOR_PASSWORD 가 비어 CI 의 docker login 이 죽는다.

jenkins.CredentialResolver 와 같은 형태다. 발급하지 않고 읽기만 한다.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Resolver

type Resolver struct {
	// contains filtered or unexported fields
}

Resolver 는 한 스택의 레지스트리 CI 변수 이름을 실제 값으로 바꾼다.

스택에 묶어 둔다. 조직·환경·스택은 번들을 조립하는 쪽이 이미 알고 있고, 그것을 호출부까지 다시 실어 나르면 유스케이스가 시크릿 경로 규칙을 알게 된다.

func New

func New(secrets SecretStore, env, orgID, stackID string) *Resolver

func (*Resolver) Resolve

func (r *Resolver) Resolve(ctx context.Context, variables []string) (map[string]string, error)

Resolve 는 요청된 변수 중 플랫폼이 아는 것만 채워 돌려준다.

모르는 레지스트리(사용자가 지정한 외부 주소 등)의 변수는 손대지 않는다. 조용히 빈 값을 채우면 CI 가 엉뚱한 자격증명으로 로그인을 시도해, 원인이 한 겹 더 멀어진다.

type SecretStore

type SecretStore interface {
	GetTokenForStack(ctx context.Context, provider, stackID, path string) (string, error)
}

SecretStore 는 자격증명 조회에 필요한 최소 동작만 노출한다.

Jump to

Keyboard shortcuts

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