Worm with Glasses

Coding • DevOps • Personal

Mar 14, 2005

Mar 13, 2005

Added Blogroll

I spent some more time tweaking my Template Toolkit templates and scripts to allow me to generate the update entries in a consistent manner. I have one WRAPPER template fragment that generates the blog-entry HTML and then the index.html template for the site grabs the five most recent entries to display on the page.

I also added a new Emacs binding to help generate the timestamp for the entry. Two key-strokes later and I have the correct entry. The Emacs Lisp I use in my .emacs is:

(define-skeleton datetime-in-t-format
  "Return the current date/time in T-combined format"
  (interactive)
  (format-time-string "%Y%m%dT%H%M%S"))
(global-set-key [?\C-c ?\C-w] 'datetime-in-t-format)

The entries are placed in the blog directory and then my index.html template processes the five more recent with the following Template Toolkit code:

# Grab the five most recent blog entries
USE dir = Directory('./src/blog', recurse=1);
SET count = 5;
FOREACH subdir = dir.dirs.reverse;
  FOREACH file = subdir.files.reverse;
    NEXT IF file.name.match('~$');
    SET blogpath = "blog/${subdir.name}/${file.name}";
    PROCESS $blogpath path = blogpath filename = file.name;
    count = count - 1;
    LAST IF count == 0;
  END;
  LAST IF count == 0;
END;

It’s a nice easy system for me to update the entries on the site.

Mar 13, 2005

Site Design

Finally, an updated design and logo for WormBytes. Every since I spun the consulting part of my job out of Flarenet, I’ve felt I needed a new design and unique logo. Well, today I found a spare few minutes to develop the little worm in the corner to go with the updated colour scheme and layout. Everyone seems to think he looks cute. I haven’t named him yet of course.

The updated site is a collection of static pages. However, I do use a bit of programming to bring everything together. To ensure a consistent look I use Template Toolkit to process a bunch of HTML fragments. Since I already use TT for dynamic websites, it makes sense to leverage the same technology to produce this site.

I have plans on updating this page often (like a blog, but let’s not call it that.) If you have any suggestions on what I should post, let me know.

Mar 12, 2005

Additions for Qpsmtpd

Plugins

These plugins are used daily by the Flarenet ISP mail server, but I have not submitted them to the Qpsmtpd maintainers. As always, use these plugins at your own risk. They work for me, but as far as I know I'm the only one using them.

check_badpatterns
Use the existing badmailpatterns and badrcptpatterns control files from the SPAMCONTROL patch.
check_domain_regexp
Compares the reverse DNS (the host/domain name) against a collection of regular expressions.
check_goodrcptto
Allow (or white-list) certain email RCPT TO email addresses or users. This is useful for allowing postmaster and abuse mail through.
rblsmtpd_env
Mimics rblsmtpd functionality with respect to the RBLSMTPD environment variable.

Pending Patches

The following patches have been sent to the Qpsmtpd mailing list, but are not currently part of the Qpsmtpd distribution. The date in brackets is the day I submitted the patch.

← Previous Page 10 of 10