trying to run planet.py via mod_python

Duarte Carreira dncarreira at gmail.com
Fri Nov 6 21:54:18 EST 2009


I have mod_python working but cannot find a way to run planet.py... no
output or error is shown on the webpage...

If someone can send me an example script I'd appreciate it.

Duarte

On Fri, Nov 6, 2009 at 12:02 AM, Alex Schröder <kensanata at gmail.com> wrote:

> On Fri, Nov 6, 2009 at 00:45, Duarte Carreira <dncarreira at gmail.com>wrote:
>
>> well i don't have access to cron in this server, just to cpanel... yes i'm
>> trying to run planet.py through some web page. It may be a cgi script, php,
>> python.
>
>
> No idea what cpanel is, but I guess you want to run the planet every now
> and then by calling a CGI script on a regular basis, and then you'll publish
> the URL to the resulting HTML file.
>
> My setup…
>
> test.ini:
>
> [Planet]
> name = Test
> cache_directory = /home/alex/planet/test
> log_level = INFO
> output_theme = musings
> output_dir = /var/www/alex/campaignwiki.org/test
> items_per_page = 5
> activity_threshold = 90
> [http://www.emacswiki.org/alex/?action=rss]
> name = Alex Schroeder
>
> test.pl CGI script:
>
> #!/usr/bin/perl
>
> use CGI qw/:standard/;
> use CGI::Carp 'fatalsToBrowser';
> print header;
> print start_html('Run Planet');
> print pre(`/home/alex/venus/planet.py /home/alex/planet/test.ini 2>&1`);
> print end_html;
>
> Output in the web page after making the script executable:
>
> INFO:planet.runner:Socket timeout set to 20 seconds
>  INFO:planet.runner:Building work queue
>  INFO:planet.runner:Feed http://www.emacswiki.org/alex/?action=rss unchanged
>
>
>  INFO:planet.runner:Loading cached data
>
> ~/campaignwiki.org $ ls test
> atom.xml  default.css  foafroll.xml  images  index.html  mutants.html
> mutants.xml  opml.xml  personalize.js
>
> Works for me… Perhaps the code examples will help you get started?
>
> Regards
> Alex
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: /archives/devel/attachments/20091106/93acab60/attachment.htm 


More information about the devel mailing list