Koozali.org: home of the SME Server

Obsolete Releases => SME Server 7.x => Topic started by: GlitchFreak on February 08, 2008, 10:58:51 AM

Title: Custom Pseudonyms Creation
Post by: GlitchFreak on February 08, 2008, 10:58:51 AM
Good day

Is it possible to create a custom set on pseudonyms on the fly when a user is created?

Also, is it possible to prevent the creation of name.surname & name_surname pseudonyms when a user is created?

Apologies if this has been answered previously. I did search but the variable names of posts is rather vast.

Thank you.
Title: Re: Custom Pseudonyms Creation
Post by: mmccarn on February 08, 2008, 03:42:01 PM
You would need to customize /etc/e-smith/events/actions/update-user-pseudonyms.
Title: Re: Custom Pseudonyms Creation
Post by: CharlieBrady on February 08, 2008, 03:48:00 PM
You would need to customize /etc/e-smith/events/actions/update-user-pseudonyms.

Better would be to provide an additional script which does what is wanted. Any customisations to update-user-pseudonyms would be lost on the next update.
Title: Re: Custom Pseudonyms Creation
Post by: GlitchFreak on February 09, 2008, 11:01:57 PM
Thanks.

With regards to the additional script, how do I make certain it runs when I add a new user?
Title: Re: Custom Pseudonyms Creation
Post by: m on February 10, 2008, 12:27:42 AM
Unfortunally the pseudonyms are created in the server-manager script. So you can either modify it with the risk to lose it on update or try this (untested!!) proposal:
Create a script /etc/e-smith/events/actions/custom-pseudonyms that removes the unwanted pseudonyms records and creates the customized pseudonyms records in the' accounts' database and finally runs the command "/sbin/e-smith/expand-template /var/qmail/users/assign"

Link this script to
/etc/e-smith/events/user-create/S01custom-pseudonyms
/etc/e-smith/events/user-modify/S01custom-pseudonyms
and
/etc/e-smith/events/user-delete/S01custom-pseudonyms