Open tufu9441 opened 4 years ago
Same here...
package main
import (
"github.com/caddyserver/caddy/caddy/caddymain"
_ "github.com/nicolasazrak/caddy-cache"
_ "github.com/captncraig/cors"
//_ ""
)
func main() {
// optional: disable telemetry
caddymain.EnableTelemetry = false
caddymain.Run()
}
Cache Plugin is there, cors plugin missing.
May be relevant difference:
Is this plugin compatible with armv7 architectures? (RaspberryPi)
This may be a tad late for @tufu9441 but I experimented a tad and found that using
_ "github.com/captncraig/cors/caddy"
worked for me, that gets it on teh list for me
this is fixed by @Silver-Golden comment, can be closed afaik
When I tried to build with the cors plugin by following steps (from https://github.com/caddyserver/caddy/tree/v1#install), the cors plugin cannot be compiled in:
main.go
file as:Run
go mod init caddy
Run![image](https://user-images.githubusercontent.com/6790361/78864187-baaac880-7a6d-11ea-8644-4e9e3a4fcf75.png)
go get -u github.com/caddyserver/caddy
Run![image](https://user-images.githubusercontent.com/6790361/78864244-d6ae6a00-7a6d-11ea-9a3d-6efbf5b068fe.png)
go build
After the Caddy binary generated, I ran![image](https://user-images.githubusercontent.com/6790361/78864299-f5146580-7a6d-11ea-8740-0174cb72df42.png)
./caddy -plugins
and didn’t see thehttp.cors
plugin listed, however thehttp.forwardproxy
plugin can be seen.