XITAMI Configuration File

XITAMI Configuration File

XITAMI Configuration file

This document shows the contents of xitami.cfg file. Note that there are some changes required in order to run PHP with Xitami. Look for the lines highlighted in yellow colour and apply the same changes in your xitami.cfg file.

#

# xitami.cfg - Xitami configuration file

#

# This file is produced automatically using GSLgen through the Xitami

# configurator. You can print it if you need a textual reference to the

# Xitami configuration options, although the HTML version is easier to use.

#

# DON'T MODIFY THIS FILE... instead, create a file called 'defaults.cfg'

# with the sections and entries you need. If you modify this file, any

# changes WON'T BE SHOWN in the browser-based admin screens. Okay, we

# warned you.

#

#*END

# ------

# SERVER configuration section

#

# This section defines general parameters for the web server.

[Server]

# Specifies the directory root where web pages are located. This can

# be an absolute directory or a relative directory.

webpages=./webpages

# Specifies the directory where CGI programs are located. This can

# be an absolute directory (starting with '/' or '\', if you prefer)

# or a relative directory (not starting with '/' or '\').

cgi-bin=./cgi-bin

# Specifies the string that Xitami uses to detect that a URL is to

# be treated as a CGI. This value must start with '/', and can

# consist of one or more paths. For instance: '/cgi', '/script',

# '/scripts/cgi'. This string does not actually refer to a real disk

# directory; it is translated into a real filename using the cgi-bin

# option, and a heuristic.

cgi-url=/cgi-bin

# Specifies the delay in seconds between each server refresh. At

# each refresh, the server does a number of administrative tasks:

# reload the configuration file if changed; reopen the file

# xitami.aut in any case; cycle the log files if necessary. The

# refresh rate has a minimum of 10 seconds, unless it is set to 0 in

# which case no refresh occurs at all. (This can be used to

# determine if the refresh is causing sporadic problems.)

refresh=60

# If 1, the server creates various debugging log files. The file

# request.log contains every incoming request. The file 'debug.log'

# in particular logs the processing of the requests. The file

# 'header.log' contains every response sent back to the browser. Use

# this to debug a virtual host configuration that gives problems, or

# to determine the cause of a recurrent problem.

debug=0

# Specifies a directory for debug log files. Xitami interprets this

# value as an environment variable if possible, else as a literal

# directory name. If you want it to refer only to a directory name,

# end it in '/'.

debug-dir=debug

# Specifies a directory for temporary files. The server creates

# these to pass information to and from CGI programs, and if

# debugging is enabled, you may find that these accumulate. Xitami

# interprets this value as an environment variable if possible, else

# as a literal directory name. If you want it to refer only to a

# directory name, end it in '/'.

temp-dir=temp

# Specifies the directory for log files. This option applies to all

# log files that Xitami creates, except debug log files. You can

# leave this option empty, and specify a full path name for each log

# file: this allows you to put different log files where you like.

log-dir=./logs

# Specifies the directory for header files. Header files contain

# custom HTTP headers, used for all files of some type. For

# instance, you can ask Xitami to output the HTTP header

# 'Cache-Control: no-cache' for all files with the extension '.txt'

# by creating a file called 'header.txt' in this directory, and

# containing the HTTP header line. Each header file matches all

# files with the same extension.

header-dir=./headers

# Specifies the maximum number of concurrent HTTP connections. On

# systems that can handle lots of open sockets (e.g. Unix, OS/2,

# WinNT, Win98), you may want to set this high. Xitami does not

# impose any fixed limit. If you set this value to 0, it means 'no

# limit'.

limit=0

# Specifies the HTTP throttle pipe. With a throttle pipe you can

# restrict the throughput of a website to some fixed maximum, e.g.

# 64Kbps. This can be useful if several websites share a single

# line, and you need to share this on a quality-of-service basis.

# The HTTP throttle pipe is applied to all download and upload

# requests to the website. You can apply a throttle pipe to the

# entire HTTP server or to specific virtual hosts. Pipes are defined

# in the XML file 'pipedef.xml'. You can edit this file to add new

# pipes; Xitami reloads this automatically after a short delay. Each

# pipe is defined as several 'instances', which are simply

# individual pipes that share the same characteristics. For example,

# the default pipedef.xml file defines several pipes with a 64Kbps

# throughput. These are individual instances of a 64Kpbs pipe. All

# transfers that use a specific pipe instance share the bandwidth of

# that pipe instance.

pipe=

# Specifies the throttle pipe definition file. This is an XML file

# that follows a specific format - look at pipedef.xml for an

# explanation. If you define your own throttle pipes, it's a good

# idea to copy pipedef.xml to something else (e.g. 'mypipes.xml')

# and then change that. This avoids unpleasant surprises when you

# upgrade your Xitami version. Note that we may change the format of

# the pipe definition file in the future.

pipedef=pipedef.xml

# If 1, the server runs as a background process, on operating

# systems that support this functionality. If 0, the server runs as

# a foreground process. Background processes are detached from their

# controlling terminal and must be halted by a system 'kill process'

# request. Foreground processes send their output to the controlling

# terminal and can be halted by an interrupt key (e.g. Ctrl-C).

# Currently, only implemented on UNIX systems.

background=0

# If 1, the server will run even if it cannot open the HTTP port. It

# will retry every 5 seconds until you stop the server (which must

# be done manually if the HTTP service cannot start). The autostart

# option applies both to the HTTP and the FTP service. This option

# is useful for systems where the network is not initially active,

# but comes 'up' after some action (e.g. dialing-up). Currently it

# is implemented only in the 32-bit Windows version of Xitami,

# mostly because this is the only platform that actually needs it.

autostart=0

# If 1, the server will try to recover from fatal errors using an

# internal crash recovery system. This currently only works under

# Windows. When this option is 0, Xitami will show a fatal error

# message and (under Windows) allow the web administrator to

# continue.

recover=0

# Specifies the sort order for directory listings. You can sort by

# file name, extension, size, or modification date/time using any

# combination of the letters 'n', 'x', 's', and 't'. For instance,

# dirsort=xnt will sort by extension, then name, then time. To sort

# in reverse order, use capital letters. For instance to show the

# most recent files first, use dirsort=T.

dirsort=n

# Specifies the GSL script that is used to format HTTP directory

# listings. GSL is a scripting language used by the iMatix GSLgen

# tool, incorporated into Xitami. A GSL script is a flexible way to

# format output texts - see the supplied script for more

# information. It's a good idea, if you change this script, to copy

# it and change the copy. Otherwise your changes will probably be

# lost when/if you ever upgrade your Xitami installation.

dir-script=templates/httpdir.gsl

# Enables or disables the supervisor agent. When enabled, the

# supervisor agent will regularly check for old log files and

# temporary files, and remove these. Temporary files are deleted

# when they are over one day old, and log files are deleted when

# they are more than two weeks old.

supervisor=0

# A number greater than 1; Xitami will allow this many requests on a

# persistent connection before closing it. Setting this to 1 has the

# same effect as disabling persistent connections (not recommended).

keep-alive-max=50

# A persistent connection will last this long before Xitami closes

# it. The timeout is specified in seconds. You can actually put this

# value quite high if wanted: the cost of an open connection is low

# and does not degrade the server performance. Anything more than a

# minute or so is probably not worth it.

timeout=30

# Specifies the default files. Up to 32 default files can be

# specified. When the user specifies a URL without filename, the

# server searches the directory for the default files, in order,

# from default1 to default32, until a matching file is found or the

# default sequence ends. Note that Xitami automatically looks for

# .html extensions if a .htm file is not found.

default1=index.htm

# Specifies the default files. Up to 32 default files can be

# specified. When the user specifies a URL without filename, the

# server searches the directory for the default files, in order,

# from default1 to default32, until a matching file is found or the

# default sequence ends. Note that Xitami automatically looks for

# .html extensions if a .htm file is not found.

default2=default.htm

# Normally, defaults pages are cached like any other. This means

# that if the browser has already loaded the page, it will add a

# HTTP request header 'If-Modified-Since'. Xitami uses this date to

# determine whether to send the page or not. In most cases, it is

# appropriate to leave this option enabled. However, if you are

# developing several sites, you may find that the browser shows the

# default page from one site when you look at another. You can clear

# the browser cache and reload, but this is usually pretty tiresome.

# To fix this disable this option and Xitami will never cache

# defaults pages.

cache-defaults=1

# Specifies whether you want to use an error script or not. When

# enabled, Xitami will pass all HTTP errors to the specified GSL

# script for processing. This is an easy and powerful way to

# customise error messages in a single place. By default this is

# disabled, for compatability with earlier releases of Xitami, but

# an error script is supplied as standard, and used if you enable

# this option.

use-error-script=0

# Specifies the GSL script that is used to format HTTP error

# messages. If you use this option, Xitami ignores error-header,

# text-xxx, and error-footer options. GSL is a scripting language

# used by the iMatix GSLgen tool, incorporated into Xitami. A GSL

# script is a flexible way to format output texts - see the supplied

# script for more information. It's a good idea, if you change this

# script, to copy it and change the copy. Otherwise your changes

# will probably be lost when/if you ever upgrade your Xitami

# installation.

error-script=templates/errors.gsl

# Specifies the text used to preface an HTTP error message. The text

# may either be HTML, or a filename prefaced by '@'. If the text

# comes from a file, Xitami will re-read this file each time it

# sends an error response.

error-header=@errors/header.htm

# Specifies the text used to end an HTTP error message. The text may

# either be HTML, or a filename prefaced by '@'. If the text comes

# from a file, Xitami will re-read this file each time it sends an

# error response.

error-footer=@errors/footer.htm

# Specifies the text used for the HTTP error 'Bad request'. This

# text can either be HTML, or be a filename prefaced by '@'. The

# text is always prefixed by the error header and suffixed by the

# error footer.

text-400=@errors/text-400.htm

# Specifies the text used for the HTTP error 'Unauthorized'.

text-401=@errors/text-401.htm

# Specifies the text used for the HTTP error 'Payment required'.

text-402=@errors/text-402.htm

# Specifies the text used for the HTTP error 'Forbidden'.

text-403=@errors/text-403.htm

# Specifies the text used for the HTTP error 'Not found'.

text-404=@errors/text-404.htm

# Specifies the text used for the HTTP error 'Precondition failed'.

text-412=@errors/text-412.htm

# Specifies the text used for the HTTP error 'Request entity too

# large'.

text-413=@errors/text-413.htm

# Specifies the text used for the HTTP error 'Internal error'.

text-500=@errors/text-500.htm

# Specifies the text used for the HTTP error 'Not implemented'.

text-501=@errors/text-501.htm

# Specifies the text used for the HTTP error 'Service temporarily

# overloaded'.

text-502=@errors/text-502.htm

# Specifies the server priority, on systems where this is possible

# (currently only Windows NT and 95). 1=normal, 2=low, 3=high. You

# can set the priority to 'low' for systems where the server should

# not interfere with other processes. You can set the priority to

# 'high' for systems where the server is the main process.

priority=1

# Specifies the IP address on which Xitami should open its HTTP

# connection. If this is *, Xitami will open its connection on all

# available IP addresses. This is normally a Good Idea, since it

# makes configuration much simpler on a multihomed system, and is

# completely correct on a single-homed system (i.e. a system with

# just one IP address, which is pretty common). If you have multiple

# IP addresses and want to run Xitami on just one of these, you can

# specify it here using the standard dotted network address format.

# This will effectively disable IP-based virtual hosting.

ipaddress=*

# Defines the IP port base for the server. Add 80 to this to

# calculate the actual port used for the HTTP service. For example,

# to run the server on port 6080, define portbase as 6000. We use a

# portbase in place of an absolute address so that multiple

# protocols (e.g. the FTP server embedded into Xitami) can be

# managed as one unit.

# portbase=0

# set portbase to 8000 to avoid any conflict with other servers

Portbase=8000

# Specifies the name of the configuration file used for the base

# virtual host. You may need this option when you have virtual hosts

# that all inherit values from defaults.cfg, but where the base host

# needs different values.

base-host=basehost.cfg

# Specifies your fully-qualified domain name for the server. This

# name is used whenever the server needs to redirect a request (e.g.

# for image maps). You may want to provide this when configuring a

# virtual host. It is not usually necessary on single-hosted

# systems. The default for this value is the system host name, or

# virtual host name for virtual hosts.

hostname=

# Specifies the name of the local configuration file. This file

# provides the defaults that are used for all virtual hosts.

# Anything in the defaults file overrides the contents of

# xitami.cfg.

defaults=defaults.cfg

# ------

# ALIAS configuration section

#

# This section lets you define HTTP aliases. An alias is a virtual

# directory that points to some arbitrary directory on the server

# computer. This can be outside the normal webpages directory, e.g.

# on another drive. Aliases can be structured into multiple levels,

# e.g. /pub and /pub/documents can both be defined as individual

# aliases. HTTP aliases always come at the start of the URL. An HTTP

# alias can also refer to a complete filename, in which case that

# file will act as the default file for the alias. To define an

# alias, specify the alias name and the directory it refers to.

[Alias]

# ------

# REDIRECT configuration section

#

# This section lets you define redirections. A redirection is like

# an alias that points to some arbitrary URL on the same or another

# server. The symbol '$' gets the text that followed the alias, also

# called the script name. For example, if you define a redirection

# alias 'go' and the user requests the URL '/go/this/place', the

# script name is 'this/place' (without a leading slash).

[Redirect]

# ------

# VIRTUAL-HOSTS configuration section

#

# This section lets you define virtual hosts. A virtual host can be

# specified in two ways: by IP address (if your system has multiple

# IP addresses) or by name (if your system has multiple names). To

# define a virtual host, specify the virtual IP address or host name

# and the name of a configuration file .

[Virtual-Hosts]