Hack 84 Creating Mail Aliases

figs/moderate.giffigs/hack84.gif

Email aliases direct mail sent to webmaster@, me@, and so forth to the right email address.

A fancy bit of email functionality in common use, especially among those with their own domain, is having mail sent to so-called vanity email addresses delivered to a single email address. This is accomplished by creating aliases for a single email address. Perhaps you'd like webmaster@ on your web site so that you can have your email application filter requests to another folder. me@ is a popular one, though I can't quite fathom why. Others include info@, support@, sales@, and godlike@ OK, so that last one's not all that common.

This hack assumes you've already set up Domain Name Service [Hack #78] and have sendmail [Hack #82] up and running.

We'll use NetInfo Manager (Applications Utilities NetInfo Manager) to create email aliases (see Figure 7-8).

Figure 7-8. Setting up mail aliases in NetInfo Manager
figs/xh_0708.gif

NetInfo was OS X's answer (prior to Mac OS X 10.2, Jaguar) to slicing, dicing, and otherwise managing both your individual local and multiple networked Macs. NetInfo Manager is a desktop application front end albeit a thin layer providing little more than a hierarchical Finder-like view to a comprehensive directory of users, groups, devices, and network services. Apple is slowly phasing NetInfo out in favor of the more esoteric yet more flexible text-based configuration files of OS X's Unix roots. Still, at the time of this writing, it's the simplest way to create email aliases.

Launch NetInfo Manager. Click the lock button ("Click the lock to make changes") at the bottom-left of the window to afford you the power to edit the current NetInfo configuration. When prompted to do so, enter your username and password and click the OK button.

Now that you're authenticated, you can get to work creating an alias. Click on the aliases entry in the center column; you'll see a list of current email aliases appear in the righthand column. Create a new entry, either by selecting Directory New Subdirectory, typing figs/command.gif-N, or clicking the "Create new directory" button the folder labeled New on the left side of your toolbar. A new directory called, appropriately enough, new_directory appears in the bottom frame of the window. Double-click the new_directory value of the Name property and rename it webmaster (or your preferred alias).

Now that you've created a new alias, you'll need to associate a real email address with it. Create a new property, either by selecting Directory New Property or typing figs/command.gif-Shift-N. Rename new_property to members and new_value to your short user name [Hack #1]. Mine's duncan.

If all went to plan, the NetInfo Manager window should now look something like Figure 7-9.

Figure 7-9. Mail addressed to webmaster will be delivered to duncan
figs/xh_0709.gif

Save your changes (figs/command.gif-S or Domain Save Changes). You will be asked to confirm your changes.

Now, any mail addressed to webmaster will be delivered to user duncan. Do the same for any more aliases you wish to create; you can add as many as you want.

James Duncan Davidson



Mac OS X Hacks
Mac OS X Hacks: 100 Industrial-Strength Tips & Tricks
ISBN: 0596004605
EAN: 2147483647
Year: 2006
Pages: 161

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net