[moin-user] moinmoin 1.9.8 : errors attempting to reset account password via shell

Paul Boddie paul at boddie.org.uk
Sat Jul 29 11:43:50 EDT 2017


On Saturday 29. July 2017 17.12.21 Lars Noodén wrote:
> On 07/29/2017 06:05 PM, Paul Boddie wrote:
> > 
> > This is what I might have written, if /home/wiki contains wikiconfig.py,
> > so we may be dealing with another problem. Can the user running this
> > command access the configuration file?
> 
> Yes, though I am not sure what level of permission is adequate.
> 
> $ whoami
> user1
> 
> $ ls -lhd /home/wiki/
> drwxr-xr-x  5 user1  user1   512B Jul 29 17:47 /home/wiki/
> 
> $ ls -lh /home/wiki/
> total 52
> drwxr-xr-x  5 user1  user1   512B Jul 14 20:39 wiki1
> -rw-r--r--  1 user1  user1   1.4K Jul 14 21:31 wiki1.py
> -rw-r--r--  1 user1  user1   819B Jul 14 21:31 wiki1.pyc
> -rw-r--r--  1 user1  user1   6.9K Jul 29 16:41 farmconfig.py
> -rw-r-----  1 user1  user1   1.6K Jul 29 16:42 farmconfig.pyc
> -rw-r--r--  1 user1  user1   571B Jul 14 20:48 log.conf
> drwxr-xr-x  2 user1  user1   512B Jul 14 20:48 logs
> -rwxr-xr-x  1 user1  user1   3.3K Jul 29 11:36 moin.fcgi
> drwxr-xr-x  3 user1  user1   512B Jul 14 21:01 underlay

These look OK to me. Obviously, what the Web server thinks is another matter, 
but given that you're running moin as user1 and the configuration files are 
read/write for user1, it should be able to read the configuration.

I see you have a farmconfig.py file. Can you specify the --wiki-url option to 
moin with the appropriate site address? Something like this...

  --wiki-url=mysite.tld/wiki1

In other words, something that will cause a match in the wikis list in your 
farmconfig.py file. In that list you might have an entry like this:

  ("wiki1" : r"^([^/]*//)?mysite.tld/wiki1(/.*)?$")

Here, the first bracketed expression just handles any scheme information. I 
can't remember whether Moin likes to present that when matching URLs, so in 
this example I include it. Maybe it could be written like this, though:

  ("wiki1" : r"^mysite.tld/wiki1(/.*)?$")

I'd have to look at the actual code to remind myself of the details.

Paul


More information about the moin-user mailing list