dbtoken

package
v0.0.0-...-37f2402 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 28 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigurePermissions

func ConfigurePermissions(ctx context.Context, dbid string, userc cosmosdb.UserClient) error

func Log

func Log(log *logrus.Entry) func(http.Handler) http.Handler

Types

type Client

type Client interface {
	Token(context.Context, string) (string, error)
}

func NewClient

func NewClient(_env env.Core, authorizer autorest.Authorizer, insecureSkipVerify bool, url string) Client

type Refresher

type Refresher interface {
	Run(context.Context) error
	HasSyncedOnce() bool
}

func NewRefresher

func NewRefresher(log *logrus.Entry, env env.Core, authorizer autorest.Authorizer, insecureSkipVerify bool, dbc cosmosdb.DatabaseClient, permission string, m metrics.Emitter, metricPrefix string, url string) Refresher

type Server

type Server interface {
	Run(context.Context) error
}

func NewServer

func NewServer(
	ctx context.Context,
	env env.Core,
	log *logrus.Entry,
	accessLog *logrus.Entry,
	l net.Listener,
	servingKey *rsa.PrivateKey,
	servingCerts []*x509.Certificate,
	verifier oidc.Verifier,
	userc cosmosdb.UserClient,
	m metrics.Emitter,
) (Server, error)

Jump to

Keyboard shortcuts

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