'Nobody": ownership of files created by makesite

A place for users and developers of the Xataface to discuss and receive support.

'Nobody": ownership of files created by makesite

Postby manifold » Wed Jun 29, 2011 9:36 am

Hello all,

This is arguably more a server administration issue than a Xataface issue, but perhaps it can be (or has been) addressed by here.

On many servers, files that are generated by the execution of a script or program (such as makesite) through the server's php or Apache engine will show the created files as being owned by 'nobody'. In the case of Xataface, files created in the templates_c directory are owned by 'nobody' and not by the creator of the file (or the logged-in user). This means that those files can not be manipulated ... or removed!

There are a variety of approaches to handling this problem (products like suPHP, CGI Wrapper, etc); but these are subject to a variety of configuration constraints which can vary by server and administrator.

Is it possible to alter the makefile script so as to add a 'chown' command (change ownership) of a file to the script, so that the file that is created has its ownership changed from 'nobody' to the logged-in user as part of the program execution? For instance, as makesite executes a 'mkdir' command, could it then execute a 'chown -R' on the created file or directory?

TIA for your suggestions!

-manifold
"Heisenberg may have slept here."

"I'm positive I've lost an electron...."
manifold
 
Posts: 31
Joined: Wed Jun 29, 2011 8:49 am

Re: 'Nobody": ownership of files created by makesite

Postby shannah » Wed Jun 29, 2011 9:51 am

If you run the makesite script under your own user account through ssh then the files will be owned by you. How are you running the makesite script?

For the templates_c directory there is a clear_cache action that will clear out the contents of this directory. Just point your web browser to your application with -action=clear_cache

e.g.
http://example.com/myapp/index.php?-action=clear_cache

-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 16 guests

cron
Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved