coderd
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Index¶
- Constants
- Variables
- type API
- func (api *API) Authorize(r *http.Request, action policy.Action, object rbac.Objecter) bool
- func (api *API) CheckBuildUsage(ctx context.Context, store database.Store, ...) (wsbuilder.UsageCheckResponse, error)
- func (api *API) Close() error
- func (api *API) CreateInMemoryAIBridgeServer(dialCtx context.Context) (client aibridged.DRPCClient, err error)
- func (api *API) RegisterInMemoryAIBridgedHTTPHandler(srv http.Handler)
- func (api *API) RequireFeatureMW(feat codersdk.FeatureName) func(http.Handler) http.Handler
- type Options
- type SCIMUser
- type TemplateACLUpdateValidator
Constants¶
const (PubsubEventLicenses = "licenses")const TimeFormatHHMM = "15:04"Variables¶
var SCIMAuditAdditionalFields = map[string]string{"automatic_actor": "coder","automatic_subsystem": "scim",}Functions¶
This section is empty.
Types¶
typeAPI¶
type API struct {AGPL *coderd.API*Options// ProxyHealth checks the reachability of all workspace proxies.ProxyHealth *proxyhealth.ProxyHealth// contains filtered or unexported fields}funcNew¶
New constructs an Enterprise coderd API instance.This handler is designed to wrap the AGPL Coder code andlayer Enterprise functionality on top as much as possible.
func (*API)CheckBuildUsage¶added inv2.25.0
func (api *API) CheckBuildUsage(ctxcontext.Context, storedatabase.Store, templateVersion *database.TemplateVersion) (wsbuilder.UsageCheckResponse,error)
func (*API)CreateInMemoryAIBridgeServer¶added inv2.27.0
func (api *API) CreateInMemoryAIBridgeServer(dialCtxcontext.Context) (clientaibridged.DRPCClient, errerror)
CreateInMemoryAIBridgeServer creates aaibridged.DRPCServer and returns aaibridged.DRPCClient to it, connected over an in-memory transport.This server is responsible for all the Coder-specific functionality that aibridgedrequires such as persistence and retrieving configuration.
func (*API)RegisterInMemoryAIBridgedHTTPHandler¶added inv2.27.0
RegisterInMemoryAIBridgedHTTPHandler mountsaibridged.Server's HTTP router ontoAPI's router, so that requests to aibridged will be relayed from Coder's API serverto the in-memory aibridged.
func (*API)RequireFeatureMW¶added inv2.14.0
typeOptions¶
type Options struct {*coderd.OptionsRBACboolAuditLoggingboolConnectionLoggingbool// Whether to block non-browser connections.BrowserOnlyboolSCIMAPIKey []byteExternalTokenEncryption []dbcrypt.Cipher// Used for high availability.ReplicaSyncUpdateIntervaltime.DurationReplicaErrorGracePeriodtime.DurationDERPServerRelayAddressstringDERPServerRegionIDint// Used for user quiet hours schedules.DefaultQuietHoursSchedulestring// cron schedule, if empty user quiet hours schedules are disabledEntitlementsUpdateIntervaltime.DurationProxyHealthIntervaltime.DurationLicenseKeys map[string]ed25519.PublicKey// optional pre-shared key for authentication of external provisioner daemonsProvisionerDaemonPSKstringCheckInactiveUsersCancelFunc func()}typeSCIMUser¶
type SCIMUser struct {Schemas []string `json:"schemas"`IDstring `json:"id"`UserNamestring `json:"userName"`Name struct {GivenNamestring `json:"givenName"`FamilyNamestring `json:"familyName"`} `json:"name"`Emails []struct {Primarybool `json:"primary"`Valuestring `json:"value" format:"email"`Typestring `json:"type"`Displaystring `json:"display"`} `json:"emails"`// Active is a ptr to prevent the empty value from being interpreted as false.Active *bool `json:"active"`Groups []interface{} `json:"groups"`Meta struct {ResourceTypestring `json:"resourceType"`} `json:"meta"`}We currently use our own struct instead of using the SCIM package. This wasdone mostly because the SCIM package was almost impossible to use. We onlyneed these fields, so it was much simpler to use our own struct. This wastested only with Okta.
typeTemplateACLUpdateValidator¶added inv2.26.0
type TemplateACLUpdateValidatorcodersdk.UpdateTemplateACL
func (TemplateACLUpdateValidator)Groups¶added inv2.26.0
func (wTemplateACLUpdateValidator) Groups() (map[string]codersdk.TemplateRole,string)
func (TemplateACLUpdateValidator)Users¶added inv2.26.0
func (wTemplateACLUpdateValidator) Users() (map[string]codersdk.TemplateRole,string)
func (TemplateACLUpdateValidator)ValidateRole¶added inv2.26.0
func (TemplateACLUpdateValidator) ValidateRole(rolecodersdk.TemplateRole)error
Source Files¶
- aibridge.go
- aibridged.go
- appearance.go
- coderd.go
- connectionlog.go
- groups.go
- idpsync.go
- licenses.go
- notifications.go
- organizations.go
- prebuilds.go
- provisionerdaemons.go
- provisionerkeys.go
- replicas.go
- roles.go
- scim.go
- templates.go
- userauth.go
- users.go
- workspaceagents.go
- workspaceproxy.go
- workspaceproxycoordinate.go
- workspacequota.go
Directories¶
| Path | Synopsis |
|---|---|
Package httpmw contains middleware for HTTP handlers. | Package httpmw contains middleware for HTTP handlers. |
Package license provides the license parsing and validation logic for Coderd. | Package license provides the license parsing and validation logic for Coderd. |