Skip to content

Latest commit

 

History

History
623 lines (364 loc) · 13.8 KB

REFERENCE.md

File metadata and controls

623 lines (364 loc) · 13.8 KB

Reference

Table of Contents

Classes

Defined types

  • postfix::config::service: define a service in master.cf file of postfix See master(5) for details
  • postfix::map: this defines a map for postfix you can either use $source or $content parameter or use your own concat::fragment resources to add content to

Classes

postfix

configure postfix, main class

Examples

include postfix

Parameters

The following parameters are available in the postfix class:

packages

Data type: Array

packages to install

Default value: ['postfix']

package_ensure

Data type: String

defaults to 'installed'

Default value: 'installed'

use_profile

Data type: String[1]

profile for the configuration to use.

Default value: 'none'

parameters

Data type: Hash

Hash of parameters for server Remark: in hiera this parameter is hash merged

Default value: {}

parameters_profiles

Data type: Hash

a Hash of profiles for parameters (see above) if $postfix::use_profile is set then and $parameters_profiles["$postfix::use_profile"] exists, the profile is merged with $postfix::parameters. Like this several config profiles can be defined (eg. mailserver, mail satellite, etc.) Remark: in hiera this parameter is hash merged

Default value: {}

services

Data type: Hash

Hash of services for server Defaults to {} Remark: in hiera this parameter is hash merged

Default value: {}

services_profiles

Data type: Hash

a Hash of profiles for services (see above) if $postfix::use_profile is set then and $services_profiles["$postfix::use_profile"] exists, the profile is merged with $postfix::services. Like this several config profiles can be defined (eg. mailserver, mail satellite, etc.) Remark: in hiera this parameter is hash merged

Default value: {}

maps

Data type: Hash

Hash of maps to generate Defaults to {} Remark: in hiera this parameter is hash merged

Default value: {}

maps_profiles

Data type: Hash

a Hash of profiles for maps (see above) if $postfix::use_profile is set then and $maps_profiles["$postfix::use_profile"] exists, the profile is merged with $postfix::maps. Like this several config profiles can be defined (eg. mailserver, mail satellite, etc.) Remark: in hiera this parameter is hash merged

Default value: {}

map_dir

Data type: String

directory for maps to create

Default value: '/etc/postfix/maps'

ssl_dir

Data type: String

directory for ssl to create

Default value: '/etc/postfix/ssl'

owner

Data type: String

file and directory owner

Default value: 'root'

group

Data type: String

file and directory group

Default value: 'root'

mode

Data type: String

file mode

Default value: '0644'

postmap_command

Data type: String

the postmap command to use

Default value: '/usr/sbin/postmap'

create_resources

Data type: Hash

generic create_resources (for certificates etc)

Default value: {}

master_cf_file

Data type: String

filename and path to master.cf file

Default value: '/etc/postfix/master.cf'

main_cf_file

Data type: String

filename and path to main.cf file

Default value: '/etc/postfix/main.cf'

postfix::config::main

configures the main.cf file

This class is included by postfix::server and postfix::satellite to write the main.cf file

Parameters

The following parameters are available in the postfix::config::main class:

main_cf_file

Data type: String

name and path of the main.cf file

owner

Data type: String

owner of the main.cf file

group

Data type: String

group of the main.cf file

mode

Data type: String

mode of the main.cf file

parameters

Data type: Hash

The parameters to set in the main.cf file Defaults to {}

Default value: {}

postfix::config::master

configure master.cf

Parameters

The following parameters are available in the postfix::config::master class:

master_cf_file

Data type: String

name and path for master.cf file

owner

Data type: String

owner of master.cf

group

Data type: String

group of master.cf

mode

Data type: String

file mode of master.cf

services

Data type: Hash

services to configure (also see README)

Default value: {}

postfix::service

create the postfix Service

Parameters

The following parameters are available in the postfix::service class:

service_name

Data type: String

The name of the service

Default value: 'postfix'

service_ensure

Data type: String

state of the service.

Default value: 'running'

service_enable

Data type: Boolean

if service should be enabled

Default value: true

disabled_services

Data type: Array

Array of Services to stop

Default value: []

exec_postfix_enable

Data type: Boolean

if set to true, we run postfix-enable

Default value: false

sync_chroot

Data type: Optional[String[1]]

if set to a path, the according chroot is synced.

Default value: undef

ensure_syslog_flag

Data type: Boolean

if set to true, and sync_chroot is choosen, a flag is set to allow logging from chroot this is very OpenBSD specific !

Default value: false

Defined types

postfix::config::service

define a service in master.cf file of postfix

See master(5) for details

Parameters

The following parameters are available in the postfix::config::service defined type:

type

Data type: String

Specify the service type. one of: inet, unix, fifo, pass. defaults to 'unix'

Default value: 'unix'

command

Data type: String

The command to be executed. defaults to $title

Default value: $title

args

Data type: Array

Array of commands arguments

Default value: []

service_names

Data type: Array

Array of service names to configure. defaults to [$title]

Default value: [$title]

priv

Data type: String

Whether or not access is restricted to the mail system. defaults '-' (use built-in default)

Default value: '-'

unpriv

Data type: String

Whether the service runs with root privileges or as the owner of the Postfix system. defaults '-' (use built-in default)

Default value: '-'

chroot

Data type: String

Whether or not the service runs chrooted to the mail queue directory. defaults '-' (use built-in default)

Default value: '-'

wakeup

Data type: String

Wake up time defaults 'n' (default for postfix >= 3.0)

Default value: '-'

maxproc

Data type: String

The maximum number of processes that may execute this service simultaneously defaults 'n' (default for postfix >= 3.0)

Default value: '-'

active

Data type: Boolean

if false, the service will not be activated (commented out) default: true,

Default value: true

comments

Data type: Array

Array of comments to print in front of the service definition. defaults to [] (no comment)

Default value: []

order

Data type: String

order of the fragment (defaults to '55')

Default value: '55'

master_cf_file

Data type: String

target

postfix::map

this defines a map for postfix

you can either use $source or $content parameter or use your own concat::fragment resources to add content to the map.

Parameters

The following parameters are available in the postfix::map defined type:

map_dir

Data type: String

the directory to create the map in

postmap_command

Data type: String

postmap command

map_name

Data type: String

The name of the map defaults to $title

Default value: $title

type

Data type: String

the type of the map defaults to hash

Default value: 'hash'

source

Data type: Optional[String[1]]

source of the map defaults to ''

Default value: undef

contents

Data type: Array

Array of lines to add to the map defaults to []

Default value: []

owner

Data type: String

owner of the map file

group

Data type: String

group of the map file

mode

Data type: String

file mode of the map file