Skip to content. | Skip to navigation


Encryptec Limited Online

 Last updated Wednesday, 27 Aug 2008 12:02
Sections
Document Actions

PloneRSS and CRON

This How-to applies to: Any version.

Howto automatically update PloneRSS feeds using CRON

This is a relatively straightforward operation on a Unix system, if any Windows users would like to contribute an equivalent mechanism then feel free.

Prerequisites

  • CRON
  • wget

Both of these should be installed by default on a Unix system. (if not :: Use the web!)

The Manager

You will need to log into Plone as a Manager and add an item of type RSS Manager. I recommend you put this in your root folder and once created, rename it to 'rss_manager'.

Once created, viewing the RSS manager should try to update any existing fields (hopefully by this point you've created a few). This screen gives you a fair bit of detail (see the screenshots) but of course updates are only activated when you view the page.

Next, add a user called cron to your Plone instance and give cron Manager privileges. (please use 'cron', this user id is hard-coded into the software)

Now you can create an appropriate crontab entry by typing;

crontab -e

then enter;

# m h  dom mon dow   command
MAILTO=<your_email_address>
0,15,30,45 * * * * wget <URL_of_your_rss_manager>/rss_manager_cron --output-file=- --output-document=-

Which will attempt to update your feeds every 15 minutes. The URL of your rss manager might be something like;
http://my_domain.com/rss_manager  (then you add /rss_manager_cron on top of this)

By default this will try an anonymous request, which will fail due to lack of permission. To fix this, edit the .wgetrc file in your home directory (this will be /root/.wgetrc if you've followed the instructions above) and add;

user=cron
password=<cron_s_password>

At which point you should be done .. every 15 mins you should see an email telling you what has been updated. Once you're happy that things are working Ok, you can filter these emails however you wish. If you don't want to see the emails, simply add the following to the wget line in the crontab statement;

> /dev/null 2>&1

..

ink toner
Get ink toner online from specialists. Get ink toner from us! We offer you the top brands for top value. Free delivery, Freephone. Call us!
Build A Website
Need a website? Want it to be simple? Use us to build a website that is suited to your every need. Click here today for more information!
IT support
Connect.co.uk provides top-notch IT Support for small and medium-sized enterprises.
Online Shopping Software...
To use e-commerce shop that works together with your company's business, click the link above.
Compatible Ink Cartridges
For remanufactured and compatible ink cartridges, click here.
Dedicated Servers>
When you experience server problems, maybe you should consider a new hosting company.
cheap laptop...
Low cost/cheap laptops found and listed here!
online back up >
Store and retrieve all your key files, databases and emails using this online backup.