Environment

Site Valet Environment

All the Site Valet programs - the Client, the valetd, and the periodic jobs, require the Valet environment variables. Since most of the Valet configuration is held in the database, only two environment variables are required:

VALET_BASE
The directory where Valet is installed. For example, /usr/local/valet.
VALET_DB_DRIVER
The full path to the driver module for the selected database. For example, /usr/local/valet/lib/PgSQL.so.

In addition, the valet library has to be at the front of the system's library path; for example by setting LD_LIBRARY_PATH.

Wrapper Scripts

The Valet system user should automatically have the environment variables in its profile, so valetd and the periodic jobs have it.

It may be less practical to impose this on users. An alternative is to supply a wrapper script or even an alias to launch the GUI:

#!/bin/sh

export LD_LIBRARY_PATH=/usr/local/valet/lib:$LD_LIBRARY_PATH
export VALET_BASE=/usr/local/valet
export VALET_DB_DRIVER=/usr/local/valet/lib/MySQL.so

exec /usr/local/valet/bin/valet

You can of course create similar wrappers for the other Valet programs too.