credentials

package
v1.13.0 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2026 License: MPL-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultPort = "12049"

Variables

This section is empty.

Functions

func GetPort

func GetPort() (int, error)

func PingURL

func PingURL(ctx context.Context, url string) error

func PostWithRetry

func PostWithRetry(port int, endpoint string, body io.Reader) ([]byte, error)

func RunCredentialsServer

func RunCredentialsServer(
	ctx context.Context,
	port int,
	client CredentialsClient,
) error

func RunCredentialsServerWithListener added in v1.13.0

func RunCredentialsServerWithListener(
	ctx context.Context,
	ln net.Listener,
	client CredentialsClient,
) error

RunCredentialsServerWithListener is like RunCredentialsServer, but takes an already-bound listener. Use this when the caller must hold the port exclusively (via net.Listen) from before startup through to serving, so no other process can bind the same port in between.

func StartCredentialsServer

func StartCredentialsServer(
	ctx context.Context,
	client CredentialsClient,
) (int, error)

Types

type CredentialsClient added in v1.10.0

type CredentialsClient interface {
	GitCredentials(
		ctx context.Context, in *tunnel.Message, opts ...grpc.CallOption,
	) (*tunnel.Message, error)
	DockerCredentials(
		ctx context.Context, in *tunnel.Message, opts ...grpc.CallOption,
	) (*tunnel.Message, error)
	GitSSHSignature(
		ctx context.Context, in *tunnel.Message, opts ...grpc.CallOption,
	) (*tunnel.Message, error)
	GPGPublicKeys(
		ctx context.Context, in *tunnel.Message, opts ...grpc.CallOption,
	) (*tunnel.Message, error)
	DevsyConfig(
		ctx context.Context, in *tunnel.Message, opts ...grpc.CallOption,
	) (*tunnel.Message, error)
}

Jump to

Keyboard shortcuts

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