On 2021-06-20, Joseph Olatt <[email protected]> wrote:
> On Thu, Jun 17, 2021 at 10:19:12PM -0600, Diana Eichert wrote:
>> "I'm trying to get rainloop PHP webmail setup on a mail server using
>> OpenBSD 6.9 httpd
>>
>> I have the webserver configured however the browser shows the mime
>> type is not correct for the css style sheet.
>> >From Firefox console,
>> "The stylesheet
>> https://mail.shopnet.com/rainloop/rainloop/v/1.16.0/static/css/app.min.css?standard
>> was not loaded because its MIME type, ???text/html???, is not ???text/css???.
>>
>> I included system mime file types in httpd.conf file as below.
>>
>> Any pointers are appreciated.
>
> My suspicion is that the extension is being assumed to be
> ".css?standard".
>
> So, try changing the following line in /usr/share/misc/mime.types:
>
> text/css css
>
> to:
>
> text/css css css?standard
>
> restart httpd and see if resolves your problem.
>
> This is just a thought.
The location matches this block:
>> location "/rainloop/*" {
>> fastcgi param SCRIPT_FILENAME "/htdocs/rainloop/index.php"
>> fastcgi socket "/run/php-fpm.sock"
>> # directory index "index.php"
>> }
so it ought to be served by rainloop's front controller in
/htdocs/rainloop/index.php and thus the content-type ought to be
dictated by rainloop..
I am wondering about the doubled path entry /rainloop/rainloop/ and
whether that is involved in the problem, perhaps making it serve
an error page not the expected css. (Opening that url directly
would prove that).
If so, perhaps httpd.conf "strip" might help (though probably the
bit that wants a component stripping is actually PATH_INFO and the
documentation doesn't talk about changing that, but it maybe the
doc rather than the code that is incomplete).