Hi,

Here's an updated way to do it.  As it turns out, postfix doesn't appear
to clear out /var/spool/postfix, so simply checking that var/run/mysqld
exists is a bad way to test whether or not to bind mount the directory.

Instead, I'm using:


                postconf -h | grep -q 'mysql:' && [ -f /proc/mounts ] && \
                                grep -q 'var/run/mysqld' /proc/mounts || {
                        mkdir -p var/run/mysqld
                        mount --bind /var/run/mysqld var/run/mysqld ||
echo "Warning: couldn't bind mount /var/run/mysqld into the `postconf -h
queue_directory` chroot!"
                }




So, checking whether or not the user is actually using a mysql: map, and
then mounting only if var/run/mysqld isn't already in /proc/mounts.





-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to