Re: [exim] Adding New Email Accounts Unix

Góra strony
Delete this message
Reply to this message
Autor: W B Hacker
Data:  
Dla: exim users
Temat: Re: [exim] Adding New Email Accounts Unix
altendew wrote:
> Sorry for my lack of information. The aliases file was EXACTLY what I needed,
> thank you =)
>


Well to embellish the simple just slightly...

If, in a system alias router, instead of:

data = ${lookup{$local_part}lsearch{/etc/aliases}}

You use:

data = ${lookup{$local_part}lsearch{/etc/{$domain}/aliases}}

- with dirtree and files to match, of course...

You can implement a cheap and cheerful domain-specific return@<domain.tld>
and/or postmaster@, webmaster@, hostmaster@, abuse@ with the responsible
party(ies) set up for single or groups of domains, and optionally a cc: to the
overall sysadmin as well.

That could survive failure of a more complex scheme, such as an SQL engine going
'hors de combat'.

HTH,

Bill


>
> W B Hacker wrote:
>> altendew wrote:
>>> I currently have over 50 sites, for each site I would like to add a new
>>> e-mail called return@???
>>>
>>> Is there anyway too add an e-mail account from the command line in Unix?
>>> Because as of right now I would have to use cpanel and login to each
>>> individual account.
>>>
>>> Thanks
>> Several.
>>
>> But you have not specified ...
>>
>> A) If all 50+, or some several subsets, are on the same/multiple servers.
>>
>> B) *Where* you keep the 'other' user information.
>>
>> In the simplest case, IF all are on the same server and IF one person
>> (yourself?) is to deal with the traffic, all you need to do is add a
>> single
>> entry to the system alias file, eg /etc/aliases on Unix, or wherever your
>> flavor
>> of Linux keeps the equivalent:
>>
>> return : <some valid on or off box email address> , <another valid..>
>>
>> That will effectively 'wildcard' all domains the server accepts for, but
>> all to
>> the same address(es).
>>
>> Otherwise, the CLI, via ssh or local, can also:
>>
>> - invoke an editor to create a script that will add that user to multiple
>> per-domain flat files
>>
>> - manually edit one or more such files.
>>
>> - run a unix tool (man sed) that can do so for a tree full of them.
>>
>> - add records to any of several types of DB or cdb database
>>
>> - add records to any of several types of SQL DB...
>>
>> Basically, if it can be done at all, it can be done with a Unix CLI either
>> directly or with help from a very rich set of tools.
>>
>> To a large extent, that is what web-based or CPanel type tools do under
>> the
>> covers anyway.
>>
>> HTH,
>>
>> Bill
>>
>>
>> --
>> ## List details at http://www.exim.org/mailman/listinfo/exim-users
>> ## Exim details at http://www.exim.org/
>> ## Please use the Wiki with this list - http://www.exim.org/eximwiki/
>>
>>
>