Manage Serendipity installations with Spartacus

Posted by ads' corner on Saturday, 2008-09-13
Posted in [Php][S9y]

I have to manage a few Serendipity (s9y) installations. Only one of them is my personal blog, the others are customer installations, all on different servers. Apart from new Serendipity versions, there’s also the problem with updated plugins. How can one know about available updates without opening each blog in a browser window, open administration, select Configure Plugins and check for new sidebar and event plugins?

Being a lazy admin (again), I decided to ask in the s9y user forum if there’s a way to automatically check each blog and Garvin came up with a modified Spartacus plugin. If you request a special blog url (containing a secret to disallow access for everyone), the status of each updateable plugin is printed. The following image shows the settings in the Spartacus configuration:

Spartacus settings
Spartacus settings

After Garvin added this functionality, I promised a script for checking the plugin update status for serendipity blogs. The source and a sample configuration file is available in my small project corner at:

The best way for using this script is to install a cronjob:

0 3 * * * php -f /path/to/spartacus_status.php -- /path/to/spartacus_status.conf

In this example the cronjob checks for updates at 3 am in the morning.

The configuration is easy:

  1. create a secret key for each blog and add it in the Spartacus configuration (see image above)
  2. open the sample configuration file, remove all examples and add your own blog url; you have to include the secret key from step 1 in the url
  3. add your own email address(es)
  4. add a cron job (see example above)
  5. make sure your PHP installation can send mails

That’s all. Now you should get a mail if plugin updates are available in one of your blogs.

If you manage more than one blog, you can add one email address which gets a copy of all updates. This email address must appear before the first blog in the configuration file. Each email address which comes after a blog definition belongs to this blog and only gets a mail if updates for this specific blog are available. With this configuration you can inform each blog owner about updates for his/her blog and still get all the details.

If you can’t run cronjobs, install both files (script and configuration file) on a webserver and open the script in your browser. You have to add the config file parameter:


Attention: Make sure that nobody else can access this url!

Protecting this url with a password is a very good idea.

Categories: [Php] [S9y]