On Mon, Sep 5, 2011 at 3:04 PM, John Robson <[email protected]> wrote: > I dont know if I understand, but if you create a init script (that run > in boot time), it'll run as 'root' then... > > # rm -rf /var/run/wt # to 'clean' wt folder in boot time
/var/run (in the future, /run) is cleared automatically, you don't need to do this > # mkdir /var/run/wt > # chown www-data:www-data /var/run/wt -R Agreed > > ... maybe start Apache2 You don't need to do this, Apache provides its own init script > or > ... /folder/site.wt --approot /folder/ --docroot /folder/ --http-addr > 0.0.0.0 --http-port 11000 > /dev/null 2>&1 & That would execute the Wt app as root, you actually want to switch to www-data: su -c "/folder/site.wt --approot /folder --docroot /folder -http-addr 0.0.0.0 --http-port 11000 > /dev/null 2>&1 &" www-data And actually, you don't need to do that if you use the start-stop-daemon scripts. For 3.1.11 I will probably provide documentation on this, and an upstart init script example (although is pretty much trivial: http://upstart.ubuntu.com/cookbook/#run-a-job-as-a-different-user ) > > This is a Linux Solution. > > On 09/05/2011 08:46 AM, Pau Garcia i Quiles wrote: >> On Fri, Sep 2, 2011 at 1:48 PM, Koen Deforche <[email protected]> wrote: >> The problem remains the same: cgi-fcgi, or whatever wrapper you write >> to start the wtfcgi app, is started by the HTTP server user, which has >> no privileges to create a directory under /var/run. > > > ------------------------------------------------------------------------------ > Special Offer -- Download ArcSight Logger for FREE! > Finally, a world-class log management solution at an even better > price-free! And you'll get a free "Love Thy Logs" t-shirt when you > download Logger. Secure your free ArcSight Logger TODAY! > http://p.sf.net/sfu/arcsisghtdev2dev > _______________________________________________ > witty-interest mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/witty-interest > -- Pau Garcia i Quiles http://www.elpauer.org (Due to my workload, I may need 10 days to answer) ------------------------------------------------------------------------------ Special Offer -- Download ArcSight Logger for FREE! Finally, a world-class log management solution at an even better price-free! And you'll get a free "Love Thy Logs" t-shirt when you download Logger. Secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsisghtdev2dev _______________________________________________ witty-interest mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/witty-interest
