mirror of
https://github.com/coder/coder.git
synced 2025-07-13 21:36:50 +00:00
feat(coderd): add endpoint to list provisioner daemons (#16028)
Updates #15190 Updates #15084 Supersedes #15940
This commit is contained in:
committed by
GitHub
parent
d7809ecf3f
commit
071bb26018
@ -379,7 +379,7 @@ func New(ctx context.Context, options *Options) (_ *API, err error) {
|
||||
//
|
||||
// We may in future decide to scope provisioner daemons to organizations, so we'll keep the API
|
||||
// route as is.
|
||||
r.Route("/organizations/{organization}/provisionerdaemons", func(r chi.Router) {
|
||||
r.Route("/organizations/{organization}/provisionerdaemons/serve", func(r chi.Router) {
|
||||
r.Use(
|
||||
api.provisionerDaemonsEnabledMW,
|
||||
apiKeyMiddlewareOptional,
|
||||
@ -393,8 +393,7 @@ func New(ctx context.Context, options *Options) (_ *API, err error) {
|
||||
httpmw.RequireAPIKeyOrProvisionerDaemonAuth(),
|
||||
httpmw.ExtractOrganizationParam(api.Database),
|
||||
)
|
||||
r.With(apiKeyMiddleware).Get("/", api.provisionerDaemons)
|
||||
r.With(apiKeyMiddlewareOptional).Get("/serve", api.provisionerDaemonServe)
|
||||
r.Get("/", api.provisionerDaemonServe)
|
||||
})
|
||||
r.Route("/templates/{template}/acl", func(r chi.Router) {
|
||||
r.Use(
|
||||
|
Reference in New Issue
Block a user