Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ConfigFileName = "config"
)
Functions ¶
Types ¶
type Auth ¶
type Auth struct { Provider string `mapstructure:"provider" default:"default"` Default DefaultAuth `mapstructure:"default"` OIDC auth.OIDCAuth `mapstructure:"oidc"` }
type Config ¶
type Config struct { Port int `mapstructure:"port" default:"8080"` GRPC GRPCConfig `mapstructure:"grpc"` EncryptionSecretKeyKey string `mapstructure:"encryption_secret_key"` Notifiers string `mapstructure:"notifiers"` // Deprecated: use Notifiers instead Notifier notifiers.Config `mapstructure:"notifier"` LogLevel string `mapstructure:"log_level" default:"info"` DB store.Config `mapstructure:"db"` // Deprecated: use Auth.Default.HeaderKey instead note on the AuthenticatedUserHeaderKey AuthenticatedUserHeaderKey string `mapstructure:"authenticated_user_header_key"` AuditLogTraceIDHeaderKey string `mapstructure:"audit_log_trace_id_header_key" default:"X-Trace-Id"` Jobs Jobs `mapstructure:"jobs"` OpenTelemetry gConfig.OpenTelemetryConfig `mapstructure:"opentelemetry"` Auth Auth `mapstructure:"auth"` }
func LoadConfig ¶
type DefaultAuth ¶
type DefaultAuth struct {
HeaderKey string `mapstructure:"header_key" default:"X-Auth-Email"`
}
type GRPCConfig ¶ added in v0.7.9
type GRPCConfig struct { // TimeoutInSeconds is the maximum time in seconds a request can take before being cancelled. Default = 5 TimeoutInSeconds int `mapstructure:"timeout_in_seconds" default:"5"` // MaxCallRecvMsgSize is the maximum message size the server can receive in bytes. Default = 1 << 25 (32MB) MaxCallRecvMsgSize int `mapstructure:"max_call_recv_msg_size" default:"33554432"` // MaxCallSendMsgSize is the maximum message size the server can send in bytes. Default = 1 << 25 (32MB) MaxCallSendMsgSize int `mapstructure:"max_call_send_msg_size" default:"33554432"` }
type Jobs ¶
type Jobs struct { FetchResources jobs.Job `mapstructure:"fetch_resources"` RevokeExpiredGrants jobs.Job `mapstructure:"revoke_expired_grants"` ExpiringGrantNotification jobs.Job `mapstructure:"expiring_grant_notification"` RevokeGrantsByUserCriteria jobs.Job `mapstructure:"revoke_grants_by_user_criteria"` GrantDormancyCheck jobs.Job `mapstructure:"grant_dormancy_check"` PendingApprovalsReminder jobs.Job `mapstructure:"pending_approvals_reminder"` }
type ServiceDeps ¶
type Services ¶
type Services struct { ResourceService *resource.Service ActivityService *activity.Service ProviderService *provider.Service PolicyService *policy.Service ApprovalService *approval.Service AppealService *appeal.Service GrantService *grant.Service CommentService *comment.Service ReportService *report.Service }
func InitServices ¶
func InitServices(deps ServiceDeps) (*Services, error)
Click to show internal directories.
Click to hide internal directories.