Bug#311821: Mixed /var and /usr

2012-06-01 Thread Stefano Zacchiroli
clone 311821 -1
retitle -1 please allow to install extensions in a FHS-compatible way
severity 311821 important
thanks

On Thu, May 06, 2010 at 09:10:55AM -0500, Romain Beauxis wrote:
 I totally second this bug report. Reading things like:
 
   Currently plugins and themes need to be dropped in by root into:
   /usr/share/wordpress/wp-content
 
 Is not really serious I believe..
 
 The usual thing done in other webapp package I maintain (mediawiki,
 spip and roundcube), is to split the directories and files that have
 to be modified and move then to /var.

I think there are two different aspects that got intermixed in this bug
report:

1) whether wordpress itself should be allowed, via its peculiar
   automatic installation mechanism over the web / ftp to install
   extensions

2) whether the machine sysadm has a way to install local extensions
   (which is badly needed, especially if (1) does not work) in some
   FHS-compatible way. Doing so directly under /usr/share/wordpress/ is
   a vary bad idea. Shipping symlinks there pointing to other locations
   (as README.Debian suggests) is only a bit better, but still a bad
   idea

I could live without (1), but I'm very surprised to discover that (2) is
not supported.  The new bug I'm creating is meant to track (2) alone.

I guess supporting (2) might be non entirely trivial, especially if
wordpress expect all plugins to be located in a single directory, rather
than being able to look them up following some kind of $PATH. So if you
want to both ship a plugin with the package (like akismet) and allow
users to install other extensions, you've a dilemma.  But it's really
badly needed, in order to allow people to manage wordpress sites in a
more Debian-ic way.

Thanks for maintaining wordpress in Debian!
Cheers.
-- 
Stefano Zacchiroli zack@{upsilon.cc,pps.jussieu.fr,debian.org} . o .
Maître de conférences   ..   http://upsilon.cc/zack   ..   . . o
Debian Project Leader...   @zack on identi.ca   ...o o o
« the first rule of tautology club is the first rule of tautology club »


signature.asc
Description: Digital signature


Bug#311821: Mixed /var and /usr

2010-05-06 Thread Romain Beauxis
Hi,

I totally second this bug report. Reading things like:

  Currently plugins and themes need to be dropped in by root into:
  /usr/share/wordpress/wp-content

Is not really serious I believe..

The usual thing done in other webapp package I maintain (mediawiki, spip and 
roundcube), 
is to split the directories and files that have to be modified and move then to 
/var.

(Purpose

/var contains variable data files.
  http://www.debian.org/doc/packaging-manuals/fhs/fhs-2.3.html#PURPOSE31)

Then, in order to make it consistent, you just have to make symlinks from /var 
to the 
files and directories in /usr and vice-versa. For instance, for mediawiki:

9:07 r...@leonard /# ll /usr/share/mediawiki
total 78K
lrwxrwxrwx  1 root root   36  1 mai   12:54 AdminSettings.php - 
/var/lib/mediawiki/AdminSettings.php
-rw-r--r--  1 root root 3,3K  5 mai2009 api.php
lrwxrwxrwx  1 root root   25  1 mai   12:54 config - /var/lib/mediawiki/config/
lrwxrwxrwx  1 root root   29  1 mai   12:54 extensions - 
/var/lib/mediawiki/extensions/
lrwxrwxrwx  1 root root   25  1 mai   12:54 images - /var/lib/mediawiki/images/
-rw-r--r--  1 root root 3,2K 21 mars   2009 img_auth.php
drwxr-xr-x 13 root root 4,9K  1 mai   12:54 includes/
-rw-r--r--  1 root root 4,2K 20 mars   2009 index.php
-rw-r--r--  1 root root 5,8K  8 mars  11:42 install-utils.inc
drwxr-xr-x  4 root root  232  1 mai   12:54 languages/
lrwxrwxrwx  1 root root   36  1 mai   12:54 LocalSettings.php - 
/var/lib/mediawiki/LocalSettings.php
drwxr-xr-x 12 root root 5,5K  1 mai   12:54 maintenance/
-rw-r--r--  1 root root 3,0K 21 mars   2009 opensearch_desc.php
-rw-r--r--  1 root root 9,0K  9 déc.   2008 profileinfo.php
-rw-r--r--  1 root root  383 21 mars   2009 redirect.php
-rw-r--r--  1 root root   91 31 janv.  2005 redirect.phtml
drwxr-xr-x  9 root root  672  1 mai   12:54 skins/
-rw-r--r--  1 root root  603  7 janv.  2009 StartProfiler.php
-rw-r--r--  1 root root 4,8K  8 mars  16:49 thumb.php
-rw-r--r--  1 root root 1,4K  5 nov.   2008 trackback.php
-rw-r--r--  1 root root   88 31 janv.  2005 wiki.phtml

And:
9:07 r...@leonard /# ll /var/lib/mediawiki
total 0
lrwxrwxrwx 1 root root  32  1 mai   12:54 AdminSettings.php - 
/etc/mediawiki/AdminSettings.php
lrwxrwxrwx 1 root root  28  1 mai   12:54 api.php - 
/usr/share/mediawiki/api.php
drwx-- 2 www-data www-data 112  1 mai   12:54 config/
drwxr-xr-x 2 root root 352  1 mai   12:54 extensions/
drwx-- 2 www-data www-data  48 16 avril 15:00 images/
lrwxrwxrwx 1 root root  33  1 mai   12:54 img_auth.php - 
/usr/share/mediawiki/img_auth.php
lrwxrwxrwx 1 root root  29  1 mai   12:54 includes - 
/usr/share/mediawiki/includes/
lrwxrwxrwx 1 root root  30  1 mai   12:54 index.php - 
/usr/share/mediawiki/index.php
lrwxrwxrwx 1 root root  38  1 mai   12:54 install-utils.inc - 
/usr/share/mediawiki/install-utils.inc
lrwxrwxrwx 1 root root  30  1 mai   12:54 languages - 
/usr/share/mediawiki/languages/
lrwxrwxrwx 1 root root  32  1 mai   12:54 LocalSettings.php - 
/etc/mediawiki/LocalSettings.php
lrwxrwxrwx 1 root root  32  1 mai   12:54 maintenance - 
/usr/share/mediawiki/maintenance/
lrwxrwxrwx 1 root root  40  1 mai   12:54 opensearch_desc.php - 
/usr/share/mediawiki/opensearch_desc.php
lrwxrwxrwx 1 root root  36  1 mai   12:54 profileinfo.php - 
/usr/share/mediawiki/profileinfo.php
lrwxrwxrwx 1 root root  33  1 mai   12:54 redirect.php - 
/usr/share/mediawiki/redirect.php
lrwxrwxrwx 1 root root  35  1 mai   12:54 redirect.phtml - 
/usr/share/mediawiki/redirect.phtml
lrwxrwxrwx 1 root root  26  1 mai   12:54 skins - 
/usr/share/mediawiki/skins/
lrwxrwxrwx 1 root root  38  1 mai   12:54 StartProfiler.php - 
/usr/share/mediawiki/StartProfiler.php
lrwxrwxrwx 1 root root  30  1 mai   12:54 thumb.php - 
/usr/share/mediawiki/thumb.php
lrwxrwxrwx 1 root root  34  1 mai   12:54 trackback.php - 
/usr/share/mediawiki/trackback.php
lrwxrwxrwx 1 root root  31  1 mai   12:54 wiki.phtml - 
/usr/share/mediawiki/wiki.phtml

That way, /var/lib/mediawiki is the main directory where the webserver should 
be configured, 
but static files and data are located in /usr...

Additionally, you can give the correct rights to the files in /var (www-data) 
so that the
automatic uploads and etc. work out of the box..


Romain



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org