Comments
Lines in the
To allow comments in your
These are standard m4 features, and you can obtain more information on them from its manual page.
VERSIONID and OSTYPE
VERSIONID(`@(#)sendmail.mc 8.9 (Linux) 01/10/98')
The VERSIONID macro is optional, but is useful to record the version of the sendmail configuration in the
OSTYPE(`linux')
This is probably the most important definition. The OSTYPE macro causes a file of definitions to be included that are good defaults for your operating system. Most of the definitions in an OSTYPE macro file set the pathnames of various configuration files, mailer program paths and arguments, and the location of directories sendmail uses to store messages. The standard sendmail source code release includes such a file for Linux, which would be included by the previous example. Some Linux distributions, notably the Debian distribution, include their own definition file that is completely Linux-FHS compliant. When your distribution does this, you should probably use its definition instead of the Linux default one.
The
DOMAIN
The
The standard installation contains a directory of m4 macro templates used to drive the configuration process. This directory is usually named
The sendmail source distribution comes with a number of sample domain macro files that you can use to model your own.
If you saved your domain macro file as
DOMAIN(`vbrew')
FEATURE
The
To use any of the features listed, you should include a line in your
FEATURE(
where
FEATURE(
where
Local macro definitions
The standard sendmail macro configuration files provide lots of hooks and variables with which you can customize your configuration. These are called local macro definitions. Many of them are listed in the
The local macro definitions are usually invoked by supplying the name of the macro with an argument representing the value you wish to assign to the variable the macro manages. Again, we'll explore some of the more common local macro definitions in the examples we present later in the chapter.
Defining mail transport protocols
If you want sendmail to transport mail in any way other than by local delivery, you must tell it which transports to use. The MAILER macro makes this very easy. The current version of sendmail supports a variety of mail transport protocols; some of these are experimental, others are probably rarely used.
In our network we need the SMTP transport to send and receive mail among the hosts on our local area network, and the UUCP transport to send and receive mail from our smart host. To achieve this, we simply include both the smtp and uucp mail transports. The local mail transport is included by default, but may be defined for clarity, if you wish. If you are including both the smtp and the uucp mailers in your configuration, you must always be sure to define the smtp mailer first.