@marcel91200 / caddy Mirror · read-only / commits / dc9dd2e4
Fork 0

Fast and extensible multi-platform HTTP/1-2-3 web server with automatic HTTPS

Mirrored from https://github.com/Slazee/caddy.git

Synced Nov 12, 14:30 UTC

caddytls: Still provision permission module if ask is specified

Only needed for JSON configs, and only temporarily as the ask property is deprecated and will be removed.

Matthew Holt committed Apr 13, 2024 at 17:08 UTC dc9dd2e4b3e266cb1267f672e3bcfd50c67cc3d4
1 file changed +7
modules/caddytls/tls.go
+7
@@ -192,6 +192,13 @@ func (t *TLS) Provision(ctx caddy.Context) error {
192 if err != nil {
193 return fmt.Errorf("preparing 'ask' endpoint: %v", err)
194 }
195 + perm := PermissionByHTTP{
196 + Endpoint: t.Automation.OnDemand.Ask,
197 + }
198 + if err := perm.Provision(ctx); err != nil {
199 + return fmt.Errorf("provisioning 'ask' module: %v", err)
200 + }
201 + t.Automation.OnDemand.permission = perm
202 }
203
204 // automation/management policies