Wydawca (split by node):   Section:   Chapter:FastBack: configuring   Up: configuring   FastForward: wydawca.conf   Contents: Table of ContentsIndex: Concept Index

4.9 Dictionaries

A dictionary defines the ways to retrieve user information necessary to verify the submission. This information can be, for example, the user’s PGP key or his permissions on a project.

A dictionary is defined in configuration file using the following syntax:

Config: dictionary { … }
dictionary dict-id {
  type type;
  query string;
  params (param1,param2,…);
}

The dictionary statement can appear either in the global scope of the configuration file, or inside a spool statement (see spool). Global definitions affect all spools in the configuration file, and ones inside a spool statement override them for that particular spool.

There are two dictionaries, identified by the value of dict-id tag:

project-owner

Keeps email addresses and real names of administrators (or owners) of a project. It may return any number of rows, each one consisting of two columns: an email address and a user name, in this order.

project-uploader

Keeps system user names, real names, emails and GPG keys of the users that are allowed to make uploads for the project.

The sub-statements of dictionary are:

Config: dictionary: type name

Defines the type of this dictionary. Name is one of the following:

builtin

The data are supplied in the configuration file.

sql

Retrieve data from an SQL database. Currently only MySQL is supported.

external

Retrieve data using an external program. This dictionary type is reserved for future use.

See below for a detailed description of these dictionary types.

Config: dictionary: query string

Sets the query used for retrieving the data. The string is subject to variable expansion (see variable expansion). The following variables are defined in this context:

project

The system name of the project for which the triplet is submitted. The project name is obtained from the directory directive. If the value of this directive contains subdirectories, the first (topmost) directory is used as ‘project’.

spool

The name of the distribution spool where this upload originates (see spool).

url

The URL of the spool, as set in the url statement of the spool block (see url).

dir

Directory (relative to the project distribution root) where the files are going to be uploaded.

dest_dir

Spool destination directory (see destination).

source_dir

Spool source directory (see source).

user
user:name

The system name of the user that submitted the triplet. This is defined only for ‘project-owner’ dictionaries.

comment

The value of the ‘comment’ field from the directive file.

Config: dictionary: params (param1, param2, …)

Supplies additional parameters.

Wydawca (split by node):   Section:   Chapter:FastBack: configuring   Up: configuring   FastForward: wydawca.conf   Contents: Table of ContentsIndex: Concept Index