squid ['installedpackages']['squid']['config'] echo "<pre>"; system("/bin/mkdir /usr/local/etc/squid"); $fout = fopen("/usr/local/etc/squid/squid.conf","w"); fwrite($fout, "http_port 127.0.0.1:3128\n"); fwrite($fout, "http_access deny to_localhost\n"); fwrite($fout, "acl our_networks src 10.0.0.0/8\n"); fwrite($fout, "http_access allow our_networks\n"); fwrite($fout, "visible_hostname insomnia.benzedrine.cx\n"); fwrite($fout, "httpd_accel_host virtual\n"); fwrite($fout, "httpd_accel_port 80\n"); fwrite($fout, "httpd_accel_with_proxy on\n"); fwrite($fout, "httpd_accel_uses_host_header on\n"); fclose($fout); $fout = fopen("/usr/local/etc/rc.d/squid.sh","w"); fwrite($fout, "#!/bin/sh\n"); fwrite($fout, "/usr/local/sbin/squid\n\n"); fclose($fout); system("chmod a+x /usr/local/etc/rc.d/squid.sh"); system("/usr/local/sbin/squid -z"); system("/usr/bin/killall squid");