update-bugdoctxt: set SSL_CERT_FILE when calling lynx

lynx doesn't seem able to use the service certificates in
/etc/ssl/certs and the SSL_CERT_DIR environment variable doesn't seem
to work either.

While at it, also run lynx as the dak-unpriv user.
上级 ee560df0
......@@ -16,7 +16,7 @@ convert () {
src=$1; dst=$2
rm -f .new-$dst
echo Generating $dst from https://www.debian.org/Bugs/$src ...
lynx -nolist -dump $urlbase$src | sed -e 's/^ *$//' | perl -00 -ne 'exit if /Back to the Debian Project homepage/; print unless ($.==1 || $.==2 || $.==3 || /^\s*Other BTS pages:$/m)' >.new-$dst
sudo -u dak-unpriv SSL_CERT_FILE=/etc/ssl/ca-debian/ca-certificates.crt lynx -nolist -dump $urlbase$src | sed -e 's/^ *$//' | perl -00 -ne 'exit if /Back to the Debian Project homepage/; print unless ($.==1 || $.==2 || $.==3 || /^\s*Other BTS pages:$/m)' >.new-$dst
if cmp -s .new-$dst $dst ; then rm -f .new-$dst
else mv -f .new-$dst $dst
fi
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册