@roland : I end up with this fix to the check-ssl test to make it work on Ubuntu
Please let me know what you think:

 debian/tests/check-ssl | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/debian/tests/check-ssl b/debian/tests/check-ssl
index 5832214..d396674 100755
--- a/debian/tests/check-ssl
+++ b/debian/tests/check-ssl
@@ -59,6 +59,24 @@ sed -e "s/^listen-address.*/listen-address 127.0.0.1:$PORT/" 
\
     < /usr/share/privoxy/config > "$CONFIG"
 echo "actionsfile $ACTION" >> "$CONFIG"

+# some autopkgtest execution environment uses proxy for internet access
+# in that case, this makes this test fail because privoxy cannot access
+# different internet resources
+# we have to configure privoxy to use the proxy configuration if present
+# in order to do that, we use the forward primitive in the privoxy 
configuration
+# file
+if [ ! -z "$http_proxy" ]; then
+    # remove http:// and https:// prefix to be compliant with forward
+    # directive input format
+    proxy_url=$(echo ${http_proxy} | sed -E 's/^\s*.*:\/\///g')
+    if [ ! -z "${proxy_url}" ]; then
+        forward_conf_snippet="forward  /  ${proxy_url}"
+    fi
+fi
+if [ ! -z "${forward_conf_snippet}" ]; then
+    echo "${forward_conf_snippet}" >> "$CONFIG"
+fi
+
 echo "Starting privoxy on port $PORT"
 $PRIVOXY --pidfile "$PIDFILE" --no-daemon "$CONFIG" > "$DAEMONOUT" 2>&1 &
 sleep 1

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2097351

Title:
  autopkgtest failures : check-ssl

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/privoxy/+bug/2097351/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to