Closed alumnihabbim closed 3 years ago
Hey @alumnihabbim. You may safely remove static
from middlewares. Could you please try w/o that option?
@alumnihabbim I found a problem. I will resolve it in the 2.3.0
, which will be released on 8 of June. Starting from the 2.2.0
release, static
will be applied automatically if you have a static
section in your .rr.yaml
(so, you can remove it from the middlewares).
@48d90782 I have tried to remove it and it works.
But in http mode you would need to serve static files.
@48d90782 I have tried to remove it and it works.
Nice to hear
But in http mode you would need to serve static files.
Static middleware will be added automatically. It's not a problem to leave it in the middlewares just for the sake of presence.
@48d90782 Sorry, in the previous test I also removed the static node from the config, only removing static from middleware I get a very similar error trace, it only starts if there is no presence of the static config:
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x10 pc=0xb3270d]
goroutine 24 [running]:
github.com/spiral/roadrunner/v2/plugins/http.applyMiddlewares(0x0, 0xc0001b9aa0, 0xc000564a80, 0x2, 0x2, 0x1586b20, 0xc00000ffb8)
github.com/spiral/roadrunner/v2@v2.2.1/plugins/http/serve.go:244 +0xad
github.com/spiral/roadrunner/v2/plugins/http.(*Plugin).serveFCGI(0xc0000e5c80, 0xc0002040c0)
github.com/spiral/roadrunner/v2@v2.2.1/plugins/http/serve.go:76 +0x2ef
github.com/spiral/roadrunner/v2/plugins/http.(*Plugin).serve.func3(0xc0000e5c80, 0xc0002040c0)
github.com/spiral/roadrunner/v2@v2.2.1/plugins/http/plugin.go:205 +0x35
created by github.com/spiral/roadrunner/v2/plugins/http.(*Plugin).serve
github.com/spiral/roadrunner/v2@v2.2.1/plugins/http/plugin.go:204 +0x6f
Yeah, I found the issue, thanks 👍🏻
@alumnihabbim in the master branch now
The current configuration is:
When starting I get the following trace:
I am using a symfony 5.3 based application