[Dbconfig-common-devel] Re: Checking if I'm right now ;)

sean finney seanius at debian.org
Sat Nov 19 18:26:30 UTC 2005


hi matthijs,

On Sat, Nov 19, 2005 at 03:43:09PM +0100, Matthijs Mohlmann wrote:
> Can you check my script it's attached (this is for libdspam7-drv-mysql)
> 
> I hope that I did it ok for dbconfig-generate-include.

while this would probably work, it isn't the way i would recommend for
three reasons:

- you rely on me never changing the values of certain variables (which
  i probably won't, but explicitly do not promise)
- doing so continues to expose sensitive information (while not on the
  cmdline, exported environment variables are typically world-visible)
- there's an easier way :)

i think you want to be doing something like:

# Load dbconfig (mysql part)
. /usr/share/dbconfig-common/dpkg/postinst.mysql
dbc_generate_include=template:/etc/dspam/dspam.d/mysql.conf
dbc_generate_include_args="-o template_infile='/usr/share/doc/libdspam7-drv-mysql/mysql.conf'"
dbc_go libdspam7-drv-mysql $@

...or something like that (i haven't tested the above, but it's the
general idea).  you then do not need to do anything at all later on
in the postinst.


	sean

-- 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.alioth.debian.org/pipermail/dbconfig-common-devel/attachments/20051119/90a98fec/attachment.pgp


More information about the Dbconfig-common-devel mailing list