Forums

Unfortunately no one can be told what FluxBB is - you have to see it for yourself.

You are not logged in.

#1 2015-03-08 22:28:59

root_hippyru
Member
Registered: 2011-03-21
Posts: 2

img/avatar outside PUN_ROOT

As far as I can see at least in fluxbb 1.5 the code assumes that the upload directory for avatars is under fluxbb installation root. This complicates hardened setups where the whole fluxbb tree is read-only with the upload directory residing in a different location where no PHP execution is not possible. This can be work-around with a symlink or a bind-mount, but this is not ideal as this prevents to use a shared source fluxbb tree, for example, between 2 different installations.

It would be nice to have something similar to FORUM_CACHE_DIR that allows to root avatars under a tree outside PUN_ROOT.

Offline

#2 2015-03-09 10:18:32

Franz
Lead developer
From: Germany
Registered: 2008-05-13
Posts: 6,047
Website

Re: img/avatar outside PUN_ROOT

Hmm, we still need to make sure the folder is available for the webserver. I guess that's why it has been done this way...

We'll see what we can do about this in v2.0.


fluxbb.de | develoPHP

"As code is more often read than written it's really important to write clean code."

Offline

#3 2015-03-09 13:06:10

seven
Member
From: Torino, Italy
Registered: 2010-08-19
Posts: 269
Website

Re: img/avatar outside PUN_ROOT

Disabling PHP execution on upload folders can be done by the webserver.

Apache users would set:

        # do not execute php on upload folders
        <Directory /<PATH_TO_FORUM>/img/avatars>
                php_admin_flag engine off
        </Directory>

while nginx users would just put a /img/avatars location block before the default location.


gamezoo.org - serious gaming services for serious gamers.

Offline

#4 2015-03-10 15:38:58

root_hippyru
Member
Registered: 2011-03-21
Posts: 2

Re: img/avatar outside PUN_ROOT

As this is an advanced feature, it should be no problem for the admin to define necessary apache aliases or nginx locations.This is how I have done it with my setup. An alternative is to define 2 prefixes, the first is a dir in the filesystem and the second is a path on the website. That would be similar how wordpress allows to customize the upload folder.

Offline

Board footer

Powered by FluxBB 1.5.8