source: trunk/LATMOS-Accounts/man/man8/latmos-accounts-base-sql.pod @ 2393

Last change on this file since 2393 was 2268, checked in by nanardon, 5 years ago

Add lastlogin attribute

File size: 9.5 KB
Line 
1# $Id$
2
3=head1 DESCRIPTION
4
5=head1 SPECIFIC SETUP PARAMTERS
6
7=head2 db_conn
8
9The C<libpq> connection parameters, eg a semin colon separated paramaters
10containing the server, the database name, user and password, etc...
11
12=head2 no_pg_utf8
13
14If set disable utf8 flags from postgresql. You can try this parameter if you
15have issue with non ascii value from database
16
17=head2 remove_old_dpmt
18
19By default when the department is changed on a user account it remains in the
20department group as a secondary department.
21
22Setting C<remove_old_dpmt> to true in the config will force user removal from
23the group when department is changed.
24The user can still be added back later.
25
26=head2 ASyncDynData
27
28Don't compute dynamic attribute at commit but let syncManager do it
29asynchronously.
30
31=head2 monitored
32
33Allow to specify monitored attributes. Monitored attributes will have their
34value logued when changed.
35
36Can be specified multiple times:
37
38    monitored=user.loginShell
39    monitored=nethost.ip
40
41=head1 FEATURES
42
43=head2 Object Aliases
44
45It is possible to create object being simple alias to another, like symbolic on
46UNIX filesystem or mail alias.
47
48Thoses aliases objects are always resolved when propagating into other base.
49The referenced object can be easilly change and all the data related will be
50propagated.
51
52Only alias for object type C<User> are supported at time.
53
54=head3 Usage Example:
55
56The typical exemple is for attribute C<manager> or attribute C<managedBy>.
57Instead setting them to C<John> you can create an alias C<Director> and when
58C<John> leave just change alias reference to C<Bill>.
59
60=head2 Network managment
61
62Link::Accounts can build automatically some part of your DNS or DHCP
63configuration.
64
65To do this you have to create a C<netzone> object. Such object need a type:
66
67=over 4
68
69=item dns: to build a DNS zone for classic domain
70
71=item reverse: for reverse IP address (168.192.in-addr.arpa)
72
73=item dhcp: ISC dscpd configuration for fixed address
74
75=item puppet: puppet configuration
76
77=back
78
79The way it works is quite simple, each zone will make the code to write a file
80you can include in your server configuration. The match is done by looking the
81zone IP address masks and the host IPs.
82
83For example someone having a zone named C<private.mydomain.com> having masks
84C<192.168.5.0/24>, and having an host named C<foo> with IP C<192.168.5.3> and
85another host C<bar> with IP C<192.168.13.78>. The zone built will look likes:
86
87    foo IN A 192.168.5.3
88
89As you can see this DNS zone is not valid: the goal of such feature is to make
90the repetive work for us, not to manage the full zone (even such feature could
91be possible). The repetitive work is declaring the hundred computers our users
92have.
93
94The output will be happend to a template have the name of the zone suffixed by
95C<.in>. You can put in this template evering about the zone declaration (SOA,
96NS, TXT...).
97
98=head2 User endcircuit
99
100The C<endcircuit> attribute contain the deadline for people to make
101admnistrative task when starting to work.
102If set this attribute take precedence to C<expire> attribute for computed
103attributes (C<accountExpires> for Active Directory).
104
105Setting C<endCircuitdontExpire> option to the database disable this behavior and
106C<endcircuit> attribute become informationnal only.
107
108=head2 Last Login attribute
109
110The C<lastlogin> attribute is designed to store the last datetime user login on
111any system. This attribute can only be set to a highter value or be unset.
112
113This allow to set this attribute from various source and to keep only the latest
114value.
115
116=head2 User Employment
117
118The employment object allow you to set time when you're user have a status. This
119allow through 'Employment' module for la-sync-manager to automate changes.
120
121The synchronized attributes are:
122
123=over 4
124
125=item C<company>
126
127=item C<employer>
128
129=item C<department>
130
131=item C<contratType>
132
133=item C<managerContact>
134
135=item C<expire>
136
137=item C<endcircuit>
138
139=back
140
141To avoid error when modifying user direclty when you're using employment those
142attribute become on user's side become read-only once an employment exists.
143
144You can change this beaviour using C<employment_lock_user> parameter:
145
146By default it is impossible to modify or create past employment. This behavior
147can be changed by settings C<allow_pasted_employment> parameter in base
148configuration.
149
150=over 4
151
152=item any (default)
153
154Any existing employment lock those attribute, you must
155create another employment to change user status or delete all employements for
156this user.
157
158=item always
159
160The user's attribute are always locked
161
162=item never
163
164The user's attribute are always locked
165
166=item active
167
168Thoses attributes are locked is any employment are still active (ie unfinished
169or coming later).
170
171=item attribute=value
172
173Thoses attributes are read-only if the C<attribute> given contains C<value>,
174C<*> allow to match any value.
175
176=back
177
178When active users become out of any employment all managed attribute are unset
179(except the expire attribute).
180
181A default value for each of this attribute can be set in configuration using
182parameter in form C<unemployment.ATTRIBUTE>. For example
183C<unemployment.contratType=external> will set any C<contratType> to C<external>
184when no employment apply to user anymore.
185
186Only active accounts are modified in this way.
187
188=head3 User endEmployment
189
190This attribute compute the next day the user will leave the company according
191the employment object registered.
192
193The parameter C<employment_delay> give the number of days to ignore when a hole
194exists between two employment.
195
196If no employment are found, if set the date given in C<unemployed_expire>
197database parameter is returned.
198
199=head3 User endStrictEmployment
200
201This attribute compute the next day the user will leave the company according
202the employment object registered.
203
204It does not take C<employment_delay> parameter into account.
205
206If no employment are found, if set the date given in C<unemployed_expire>
207database parameter is returned.
208
209=head3 User endLastEmployment
210
211This attribute return the very last end of all registered employment fr this
212user.
213
214=head3 User endCurrentEmployment
215
216The end of the employment matching current date.
217
218=head3 Account Expiration
219
220When using employment, account expiration are set to match employment. By
221default the expiration is set to C<endEmployment> value.
222
223This behaviour can be changed by setting C<expireOn> parameter into base
224definition:
225
226=over 4
227
228=item any of endCurrentEmployment, endEmployment, endStrictEmployment, endLastEmployment
229
230=item never
231
232The expire date is left unchanged and must managed manually.
233
234=back
235
236=head2 Group AutoMemberFilter
237
238Group objects contains users members by setting either C<members> or
239C<memberUID> attributes.
240
241Sometimes it can be usefull to have group automatically populated by arbitrary
242rules.
243
244This is possible by setting a filter in the C<autoMemberFilter> attribute,
245The filter format is the same the one used by L<la-search>, the attribute is
246multivaluable.
247
248So for example one can create an account automatically a group containing people
249having "Olivier" as first name:
250
251    autoMemberFilter: givenBame=Olivier
252
253A probably more usefull example is a group containing people from two others
254groups:
255
256    autoMemberFilter: memberOf=group1
257    autoMemberFilter: memberOf=group2
258
259The  C<members> or C<memberUID> attribute becomes read-only attribute once
260C<autoMemberFilter> attribute is set.
261
262=head2 Aliases AutoMemberFilter
263
264This attribute allow to create automatics dynamics aliases according filter
265rules exactly like L<Group AutoMemberFilter> works.
266
267The C<forward> attributes is automatically set with email address of selected
268user, user w/o email address are ignored.
269
270=head2 Group AutoFromSutype
271
272Group object can be tagged with the C<sutype> attribute.
273
274When C<autoFromSutype> is set the group member will be computed from member of
275all groups having C<sutype> set this value.
276
277The goal of this attribute is to setup magic group like with the
278C<autoMemberFilter> but working even a new group is created.
279
280=head2 Aliases AutoFromSutype
281
282This attribute allow to create automatics dynamics aliases according filter
283rules exactly like L<Group AutoFromSutype> works.
284
285The C<forward> attributes is automatically set with email address of selected
286user, user w/o email address are ignored.
287
288=head2 Statistics
289
290The application provide some statitics tools but they are only based on the
291current data inside the database and are unable to track delete data.
292
293To keep some mesurement you must use C<stat> objects to describe the data you
294want to track, and enable in L<la-sync-manager.ini> the C<Stats> module.
295
296Each attribute of C<Stat> object describe how data must but compute before being
297stored.
298
299=head3 Stat object Attributes
300
301=head4 description
302
303A label about this statistics object
304
305=head4 display
306
307IF set the statistic appear in the menu of the web interface
308
309=head4 otype
310
311The object type this stat is tracking, must be a supported object type
312
313=head4 filter
314
315One or multiple filter to limit the objects taking into account
316
317=head4 attribute
318
319The attribute fetch to compute data
320
321=head4 refFilter
322
323When the attribute reference another type of object this setting allow to
324filter to the matching referenced object.
325
326=head4 refAll
327
328When the attribute reference another type of object non exiting objects in
329the results appear as 0, otherwise they are ignored.
330
331=head4 aggregateFunction
332
333An optionnal operation to do on the data:
334
335=over 4
336
337=item sum
338
339Make the sum of the result per item
340
341=item avg
342
343Make the average of the result per item
344
345=item count
346
347Count the number of item return
348
349=back
350
351=head4 delay
352
353The number of day between two run
354
355=head4 retention
356
357If set, the duration in days after which stats value must deleted
Note: See TracBrowser for help on using the repository browser.