imip-agent

Annotated README.txt

147:ee2bd0ee8f55
2015-01-12 Paul Boddie Moved common filesystem functionality into a new module. Added preferences support so that the timezone and locale associated with individual users can be retrieved and used to configure the management interface. Made the default permissions of stored data a configuration setting.
paul@102 1
imip-agent
paul@102 2
==========
paul@102 3
paul@102 4
This software implements an agent that can interpret e-mail messages
paul@102 5
containing calendar information, maintain availability records for scheduling
paul@102 6
participants, act on behalf of resources and other entities that need to
paul@102 7
participate in scheduling, and support user interfaces for end-users whose
paul@102 8
e-mail programs do not understand calendar data.
paul@102 9
paul@102 10
Getting Started
paul@102 11
===============
paul@102 12
paul@102 13
Eventually, this information should be incorporated into packages for various
paul@102 14
operating system distributions, and these instructions should be largely
paul@102 15
superfluous for most users.
paul@102 16
paul@102 17
System User and Filesystem Access
paul@102 18
---------------------------------
paul@102 19
paul@102 20
A system user needs to be created and to belong to certain groups in order to
paul@102 21
deliver messages to mail stores and to publish resources on the Web:
paul@102 22
paul@102 23
  useradd -d /var/lib/imip-agent -m -U -G lmtp,www-data -r imip-agent
paul@102 24
paul@102 25
If the lmtp group does not exist, it should be created and be employed for
paul@102 26
LMTP delivery to systems like Cyrus and Dovecot.
paul@102 27
paul@102 28
Store details and published resources need to be accessible by the imip-agent
paul@102 29
and www-data users:
paul@102 30
paul@147 31
  mkdir /var/lib/imip-agent/store /var/lib/imip-agent/preferences
paul@147 32
  mkdir /var/www/imip-agent/static
paul@147 33
  chown imip-agent /var/lib/imip-agent/store /var/lib/imip-agent/preferences
paul@147 34
  chown imip-agent /var/www/imip-agent/static
paul@147 35
  chgrp www-data /var/lib/imip-agent/store /var/lib/imip-agent/preferences
paul@147 36
  chgrp www-data /var/www/imip-agent/static
paul@147 37
  chmod g+ws /var/lib/imip-agent/store /var/lib/imip-agent/preferences
paul@147 38
  chmod g+ws /var/www/imip-agent/static
paul@102 39
paul@102 40
Here, the setgid flag should ensure that new files and directories have the
paul@102 41
appropriate group associated with them.
paul@102 42
paul@102 43
Fixing ownership can be done as follows:
paul@102 44
paul@102 45
  chown -R imip-agent /var/lib/imip-agent
paul@102 46
  chgrp -R imip-agent /var/lib/imip-agent
paul@147 47
  chown -R imip-agent /var/lib/imip-agent/store /var/lib/imip-agent/preferences
paul@147 48
  chown -R imip-agent /var/www/imip-agent/static
paul@147 49
  chgrp -R www-data /var/lib/imip-agent/store /var/lib/imip-agent/preferences
paul@147 50
  chgrp -R www-data /var/www/imip-agent/static
paul@147 51
  chmod -R g+w /var/lib/imip-agent/store /var/lib/imip-agent/preferences
paul@147 52
  chmod -R g+w /var/www/imip-agent/static
paul@102 53
paul@102 54
Installing the Software
paul@102 55
-----------------------
paul@102 56
paul@102 57
The tools/install.sh script should install the software in appropriate
paul@102 58
locations.
paul@102 59
paul@102 60
Configuring Other Software
paul@102 61
--------------------------
paul@102 62
paul@102 63
The conf directory contains subdirectories for different systems:
paul@102 64
paul@102 65
  apache        Apache 2 site configuration for publishing resources
paul@102 66
  exim          Exim 4 routing and transport configuration
paul@102 67
  postfix       Postfix routing and transport configuration
paul@102 68
paul@102 69
Either Exim or Postfix can be chosen as a mail system supporting the agent.
paul@143 70
paul@143 71
Configuring Mail Systems for the Agent
paul@143 72
--------------------------------------
paul@143 73
paul@143 74
The essential aspect of mail system configuration involves mail transports and
paul@143 75
the integration of agent programs into the mail processing pipeline. Thus, the
paul@143 76
following files are of particular interest:
paul@143 77
paul@143 78
For Exim...
paul@143 79
paul@143 80
  conf/exim/30_exim4-config_people              Integration of agent programs
paul@143 81
  conf/exim/30_exim4-config_people_outgoing     ...
paul@143 82
  conf/exim/30_exim4-config_resources           ...
paul@143 83
paul@143 84
For Postfix...
paul@143 85
paul@143 86
  conf/postfix/master.cf.items      Integration of agent programs (for
paul@143 87
                                    inclusion in master.cf)
paul@143 88
  conf/postfix/transport            Configuration of agent transports
paul@143 89
  conf/postfix/virtual              Configuration of outgoing mail routing
paul@143 90
paul@143 91
Such files need adjusting for the deployment environment so that, for example,
paul@143 92
the example.com domain would be replaced with a suitable value.
paul@143 93
paul@143 94
Where $lmtp_socket is employed, a suitable filesystem path is required; see
paul@143 95
below for a discussion of LMTP and mail delivery.
paul@143 96
paul@143 97
Configuring Mail Systems for Mail Recipients
paul@143 98
--------------------------------------------
paul@143 99
paul@143 100
The software should operate independently of the way mail recipients are
paul@143 101
identified in any given mail system, and thus does not dictate things such as
paul@143 102
routing or account querying. However, example configuration files are provided
paul@143 103
that demonstrate the use of LDAP to identify mail recipients:
paul@143 104
paul@143 105
For Exim...
paul@143 106
paul@143 107
  conf/exim/010_exim4-config_people_outgoing    Defines recipients and
paul@143 108
                                                outgoing mail routing
paul@143 109
  conf/exim/890_exim4-config_ldap_people        ...
paul@143 110
  conf/exim/890_exim4-config_ldap_resources     ...
paul@143 111
paul@143 112
For Postfix...
paul@143 113
paul@143 114
  conf/postfix/local_recipient_maps.cf          Defines local virtual
paul@143 115
                                                recipients
paul@143 116
  conf/postfix/main.cf.example                  Defines recipients and outgoing
paul@143 117
                                                mail routing (for inclusion in
paul@143 118
                                                main.cf)
paul@143 119
  conf/postfix/virtual_alias_maps_people.cf
paul@143 120
  conf/postfix/virtual_alias_maps_people_outgoing.cf
paul@143 121
  conf/postfix/virtual_alias_maps_resources.cf
paul@143 122
paul@143 123
With the exception of the sender_bcc_maps setting in Postfix's main.cf, the
paul@143 124
above recipient identification configuration examples can be disregarded in
paul@143 125
favour of other ways of defining mail recipients, subject to the needs of any
paul@143 126
given environment.
paul@143 127
paul@144 128
LDAP Representations for Mail Recipients
paul@144 129
----------------------------------------
paul@144 130
paul@144 131
Relevant LDAP resources for structuring recipient information include the
paul@144 132
following:
paul@144 133
paul@144 134
  RFC 4524  http://tools.ietf.org/html/rfc4524  Defines the mail attribute
paul@144 135
  RFC 2798  http://tools.ietf.org/html/rfc2798  Defines the inetOrgPerson
paul@144 136
                                                object class
paul@144 137
  RFC 2739  https://tools.ietf.org/html/rfc2739 Defines the calEntry object
paul@144 138
                                                class supporting calFBURL
paul@144 139
paul@144 140
An additional draft RFC describes the mailRecipient object class:
paul@144 141
paul@144 142
  https://tools.ietf.org/html/draft-lachman-ldap-mail-routing-03
paul@144 143
paul@144 144
Resource schemas for LDAP are not effectively standardised for the purposes of
paul@145 145
this software. A useful object class, inetResource, was defined for the
paul@145 146
iPlanet Calendar Server:
paul@145 147
paul@145 148
  http://docs.oracle.com/cd/E19566-01/819-4437/6n6jckqrf/index.html#anocg
paul@145 149
  http://docs.oracle.com/cd/E19566-01/819-4437/6n6jckqr8/index.html
paul@145 150
paul@145 151
Although Kolab maintains notions of resources, they are tied up with the
paul@145 152
notion of a shared folder and the kolabSharedFolder object class, although the
paul@145 153
mailRecipient object class is employed by resources in Kolab.
paul@144 154
paul@143 155
Configuring Mail Systems for Mail Delivery
paul@143 156
------------------------------------------
paul@143 157
paul@143 158
The agent software assumes that delivery of mail to recipients may be
paul@143 159
performed using LMTP to a suitable mailbox provider. This is largely beyond
paul@143 160
the scope of this document, but systems such as Cyrus and Dovecot can be
paul@143 161
configured to provide a Unix domain socket offering support for LMTP
paul@143 162
connections.
paul@133 163
paul@133 164
Prerequisites
paul@133 165
-------------
paul@133 166
paul@133 167
Depending on the mail transport agent (MTA) chosen, the following packages are
paul@133 168
required for this software to work on Debian systems:
paul@133 169
paul@133 170
  Exim:    exim4-daemon-heavy
paul@133 171
  Postfix: postfix postfix-ldap