freescout-help-desk / freescout

FreeScout — Free self-hosted help desk & shared mailbox (Zendesk / Help Scout alternative)
https://freescout.net
GNU Affero General Public License v3.0
2.94k stars 484 forks source link

Openlitespeed attachments #3701

Closed xyzulu closed 8 months ago

xyzulu commented 8 months ago

I've used Freescout on Apache and Nginx, and only a few small tweaks are needed on Nginx. Freescout works out of the box on Openlitespeed as well.. BUT attachments do not work (404 errors). We understand why, the files are not web accessible and need to be "routed" via Freescout before they are visible or downloadable.

I've reached the end of my experience trying to get this to work and I am surprised there doesn't appear to be any information out there on this either. Any ideas on how this might be achieved in OLS? I have to give up trying for now.. ;)

This is the nginx equivalent we are trying to achieve:

location ~* ^/storage/attachment/ {
        expires 1M;
        access_log off;
        try_files $uri $uri/ /index.php?$query_string;
freescout-helpdesk commented 8 months ago

Unfortunately we don't have a config for Openlitespeed. If you'll find a solution feel free to share.

Here is where attachments are being passed for download: https://github.com/freescout-helpdesk/freescout/blob/dist/app/Http/Controllers/OpenController.php#L196