Skip to content


Folders and files

Last commit message
Last commit date

Latest commit


Repository files navigation


Web page

Singleshot's home page is
There you will find this information as well as the current release.


Web-based photo album software that requires minimal work after initial
setup. There is no external data and your album hierarchy can be maintained
by updating the files and directories in that tree. The administrator of the
singleshot installation can use Web server permissions to restrict access to

Singleshot does not require a special process or program for sharing photos.
You post the photos to your albums using the file upload program of your


You will need the following software installed on your web server
to install Singleshot.

   * Apache with mod_rewrite
   * Python 2.5+
   * ImageMagick

Singleshot relies on setting mod_rewrite directives in .htaccess.
This facility needs to be enabled on the web server.

You will also need an appropriate unpacking tool to unpack the
Singleshot archive.


album root
    The directory that will become the root album of your new
Singleshot installation. Apache needs to be configured to serve this

    File with directives to Apache to set up permissions, rewrite
rules, or other options. Singleshot comes with two of these, one for
the singleshot directory and one for the album root.



1. Download and unpack Singleshot.

2. If you want Singleshot installed with the other Python libraries in
site-packages, run python install.  Otherwise, skip this

3. To set up a new album root using Singleshot, use the script.  It's in the scripts/ directory of the
unpacked SIngleshot distribution, or with the other
Python-library-installed scripts if you installed Singleshot into

4. Run -h to see a list of the command line options.
Generally, you'll want either the --standalone install.  If you
installed Singleshot in a place not normally on sys.path (e.g. by
using the --home option to install), you'll need to either
put that on PYTHONPATH before running singleshotinit or tell
singleshot init about it using --path.

For example, suppose I wanted to get Singleshot running in my personal
web directory ~/public_html/photos which will show up on my web server
as /~fox/photos/ and I didn't want to install it in site-packages.

I'd unpack Singleshot's archive, cd into the directory, and run

./scripts/ --root ~/public_html/photos --url /~fox/photos/ --standalone

Configurable things

Where ALBUMROOT is where you put your album root (--root above):

ALBUMROOT/_singleshot.cfg can also have (and default to the values below):


The imagesizes section is very important: it limits what sizes of
images can be requested from your album originals.  With the above
configuration, downloads are limited to a max of 40, 200, 600, or 1200
pixels on a side. (That is, any picture downloaded will be scaled down
from the original size to one of the appropriate sizes) In a template,
referring to a size by number means 'show me that size or nothing',
but referring to a size by name means 'show me a permitted size no
larger than the one I asked for'.

_album.cfg in every directory can have:

    title=foo                ; sets the title of the album to foo
    highlightimage=file.jpg  ; uses file.jpg (in the current dir) as the 'cover' of the album
                             ; default is to use the first image in the directory
    order=dir,title,-mtime   ; sort order for display.  Valid orders are:
                             ;   title, dir, mtime, exifdate, name, href
                             ;  prepending '-' sorts in descending order instead of ascending 

ALBUMROOT/pages can be a directory with files in it.   foo.html will show up as URLROOT/foo/ and will display the contents of foo.html.

This is to enable you to easily create static pages on the site with the photos.

Writing templates
----------------- describes the syntax of the templating system used by Singleshot 2.x.

(** document attributes and objects exposed to templates **)


Singleshot Web Album Software







No releases published