Re: .qmail file
Bruce Guenter <[email protected]> Thu, 16 Dec 2010 19:11:35 -0600
| Newsgroups | gmane.comp.sysutils.bgware |
|---|---|
| Message-ID | <[email protected]> |
--EuxKj2iCbKjpUGkD Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Dec 16, 2010 at 03:20:39PM -0300, Marco Aur??lio wrote: > I'm new using qmail-autoresponder and i compiled it for mysql use. > My question is: how can i enter the database infos into the .qmail=20 > ($MYSQL_USER, $MYSQL_HOST, $MYSQL_PASS, $MYSQL_DB and $MYSQL_SOCK)? > I tested using mysql on localhost, but my qmail database is on another=20 > server so i need to tell qmail-autoresponder-mysql where to connect. The easiest way is to just stick the assignments in front of the program like this: | MYSQL_USER=3D... qmail-autoresponder-mysql ... If that doesn't work with your shell (it works with bash, dash, and ksh), you might need to add "env" in front of that. However, it would be preferable to use either envdir: | envdir /path/to/whatever qmail-autoresponder-mysql ... and put the settings into that directory so they could be reused by other things. Even better would probably be to put them in .my.cnf since qmail-autoresponder-mysql is written to read them there: [qmail-autoresponder] host =3D mysql.example.com database =3D autoresponders ... --=20 Bruce Guenter <[email protected]> http://untroubled.org/ --EuxKj2iCbKjpUGkD Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (GNU/Linux) iEYEARECAAYFAk0KuMcACgkQ6W+y3GmZgOjqBQCgmgPs3BqWU97PsV7eO2wC/xcx GFMAoJ/n03y0bahgQkoarQxt013JHUED =P45a -----END PGP SIGNATURE----- --EuxKj2iCbKjpUGkD--