WACS: Configuration

Contents

Overview

For the configuration files, buzz-word compliance comes to the fore - it's all implemented in XML for your intense visual displeasure! Seriously, the perl module XML::Simple makes it very easy to read configuration files written in this way. It also provides an extensible frame work for future work including a much needed generic interface to web site (source of material) links and information.

Sections

The XML configuration file is divided into a number of sections, each one associated with a different aspect of how Wacs works. The sub-sections below detail each of these and the currently defined keywords within those sections.

Sections: Database

Variable Description Typical Value
dbienvvar Commerical databases such as Oracle 10g usually require the presence of an environment variable to tell their libraries where to find configuration information, libraries, etc. This is the name of that variable; the companion attribute, dbienvvalue, is what value that variable should have. ORACLE_HOME
dbienvvalue The value that dbienvvar should be set to; typically the location of the installed database library and configuration files for the database. /usr/local/oracle/V10.1.0
dbiconnect This is the connect string that needs to be passed to the perl DBI routines to specify the database type and instance to be connected to. For Oracle it'll be something like dbi:Oracle:orasrv where orasrv is the SID of the database. For MySQL it'll be something like dbi:mysql:wacs:myserver where wacs is the database name and myserver is the name of you database host. dbi:Oracle:orasrv
dateformat This is the format of date used by the underlying database - initially this will be either DD-MON-YYYY (the Oracle format) or YYYY-MM-DD (the MySQL format). YYYY-MM-DD
dbuser The username to log into the database with. wacs
dbpass The password to log into the database with. wacs

Sections: Tables

Variable Description Typical Value
models name of the models tables. This is indirected to allow for databases to be owned by a different user than the wacs system runs as or for porting considerations to other database platforms. In Oracle you might call it dbowner.models rather than the normal simple models. models
idmap name of the idmapping table - this is the one that links a local model to a model name/number for a specific site. idmap
assoc name of the associations table, ie the one that links a model to a given set. A single set can have many associations, if it has a lot of known models in it. assoc
sets name of the sets tables. Cornerstone of Wacs. sets
download name of the download tables. Used to identify the source information for a set. Depending on status can either be a task list, or a check list of what we already have. download
photographer name of the photographer table. Where the list of known photographers is. photographer
tag name of the tag table. This is the search results and bookmarking mechanism tag

Sections: Server

The server section contains URLs for your web server. Note that EVERY URL stem given here is a directory and includes the final forward slash (/). The programs do make the assumption they only need to append the program/file name to these URL stems.
Variable Description Typical Value
baseurl The "base" URL of your web server, ie the top level page http://www.example.com/
cgiurl The URL of your cgi-bin directory on your web server. If you intend to use subdirectories for Wacs within the cgi-bin directory, include that here. http://www.example.com/cgi-bin/
iconurl This where the attribute and rating icons are to be found on your web server. These are the glyphs and artwork components. Not to be confused with the model "headshot" icons, which are expected to be in the icons sub-directory of the Wacs document tree. http://www.example.com/wacs/glyphs/
wacsurl This is the URL for the Wacs document tree itself, ie where the htmlbones index.php and other menu segments go. http://www.example.com/wacs/

Sections: File System Locations (fsloc)

These values direct Wacs as to where to find the files it should be serving out. Note that in a normal setup these would not be within the web server tree at all, thus making Wacs the gateway to web access of them. Accessing them directly rather than through Wacs could mean loss of all access and login control, and that the URLs would contain more obvious paths giving a better clue to their nature.
Variable Description Typical Value
images Location within the filesystem of the top of the images tree from which Wacs is to operate. /home/wacs/images
videos Location within the filesystem of the top of the videos tree. /home/wacs/videos
glyphs Location of the glyphs (icons and artwork) within the file system. /var/www/html/wacs/glyphs
seticons Where the small icons for each set generated by generate are to be placed, and thus where the wacs programs can fetch them from. /home/wacs/data/iconcache
officons Location where the official icons provided by the source site are stored; these are not necessarily even close to the thumbnails we generate from the image sets themselves and we may well not have them for all sets, depending upon where the sets came from. These will only be used if their location is specified in the sofficon fields in the sets table. /home/wacs/data/seticons
vidicons Where the icons for video files can be found. /home/wacs/data/vidicons
dvdicons Where the icons for DVD covers can be found (for a future project where Wacs knows about appearances by your favourite models on DVDs in your collection). /home/wacs/data/dvdicons
modicons Where the normal-sized headshot icons for the models are to be found. These are usually around 120 x 156 pixel jpeg images. /var/www/html/wacs/icons
modbigicons Certain Wacs applications (like wacsmodelpage) will use a larger icon for the model if present, these are typically somewhere around 250 x 300 pixel jpeg images but can vary quite considerably. This is the location of these larger icons. /var/www/html/wacs/bigicons
thumbcache When wacsthumbs creates a set of thumbnail images for a set, these are cached to speed display on a future occasion. This is the location where this cache is stored. /home/wacs/cache
download Specifies the directory into which new downloads are to be placed. This will be used by the download tools in a future version. /home/wacs/download
leasedir This specifies the directory in which the leases file will be created. If this does not exist, the lease file (name as specified below in the security section) will be created in /tmp. /var/run/wacs

Sections: Security

This contains the attributes used by the security mechanism to determine whether a given user should be allowed to log in and if so, how long their lease should last for.
Variable Description Typical Value
barredusers A comma separated list of those valid users of the server system who are not allowed to log into WACS. Most likely this might be the kids or possibly spouses who would take exception to the material - the consequences of putting people in this list are on your head! wilma,barney
powerusers A list of people who should be granted power user status when they login through wacslogin. This enables manipulation of tag lists and in due course, ratings, etc. dino
adminusers The highest grade of access - administrators allowed to do anything in the Wacs system tools. fred,root
leasetime The period in hours (number with an h after it) or minutes (number with an m after it) that a lease should be granted for to a given IP address; this could be fairly long lived if it's mainly a friends ADSL line which may change periodically (say 24 or 48), or fairly short if you worry about a subsequent user on the same PC as you were surfing from (say 1 or 2). 24h
leasefile The name of the leases file. This will be in the location specified by the leasedir option in the fsloc (file system locations) section, unless that doesn't exist, in which case it'll be created in /tmp. This file is in the same format as the permanent access control list in the Wacs configuration directory. leases.acl

Sections: Colours

The colours section gives Wacs some general hints on which colours to use when. Not all of the Wacs programs yet pay attention to these settings but it is a future direction that they should! And yes, I know it's not spelt the American way, but hey the language is called English, right? So you get to learn to spell it the correct English way for a change! After all, we have to spell it the American way in every web page we write.
Variable Description Typical Value
foreground The foreground colour of web pages in HTML standard six-octet notation. #000000
background The background colour of web pages in HTML standard six-octet notation. #FFE8FF
setbackground The background colour of an image set entry in various pages; note in particular that this colour hint can be the only visual differentiator between images and videos in the likes of wacsmpthumbs and wacsimglist - think about this before making it the same as the other two background settings below. #FFB0FF
vidbackground The background colour of a video set entry in various pages. See note above. #FFFFB0
dvdbackground The background colour of a DVD set entry in various pages. See note above. #B0FFB0
divider The colour of the section divider in various indexes. #FFA0A0

Sections: Layout

This controls the number of columns of set icons that Wacs will try to display and how big those icons will be. Other variables to control more aspects of layout, including model index layouts will no doubt follow. Many of these values are still hard coded in the scripts, but this should change over time.
Variable Description Typical Value
thumbsize The maximum size of thumbnails for a set. Obviously since most images are not square, this will typically be the larger of whichever two dimensions the icon has. 220
thumbcount Number of set thumb nails to be displayed going across the web page. 4
minisize The size of minature icons for a set. These are typically dynamically resized by wacsimg on request. 110

Sections: Precedence

This is a more complex section since most of the precedences are determined by how you've set up "areas" (aka sarea) on your image collection. The default section should always be present, but the others are named for the areas you've chosen. The algorithm is: look for a precedence setting of either models or sets for the given sarea, and failing that, return the default value. So if you have sareas of "favourites", "amkingdom" and "usenet" and want indexes to show models thumbnails in "favourites" and "amkingdom" but set thumbnails in "usenet", you would make this section read:
 <precedence>
  <default>models</default>
  <usenet>sets</usenet>
 </precedence>
Variable Description Typical Value
default What the "normal" precedence should be, models or sets. models
sarea_name Override the precedence for the specified sarea_name to be the value specified (usually opposite of the default). sets

Next Section: Web Applications
Back to WACS Documentation Index