...

Package rpc

import "golang.conradwood.net/tests/shared/rpc"
Overview
Index

Overview ▾

Constants

const (
    CTXKEY = "go_easyops_ctx_key"
)

func ContextToString

func ContextToString(ctx context.Context) string

func ContextWithLogin

func ContextWithLogin(username string, password string) (context.Context, error)

func GetUser

func GetUser(ctx context.Context) *apb.User

func NewContextWithUserAndService

func NewContextWithUserAndService(ctx context.Context, user, service *apb.User) context.Context

adds this services' user & service accounts to context and returns it

func PrintContext

func PrintContext(ctx context.Context)