lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

I don't know lua-sockets, but if it works like the Python lib, you
should set the http_proxy environment variable in your bash shell
(export http_proxy="http://username:password@proxyhost:8080/";).

not in your lua script.

If lua-sockets does not support proxy at all, then you'll have to
write your own code to support proxy.

> #!/bin/lua
> local http = require("socket.http")
> PROXY="http://username:password@proxyhost:8080/";
> local a,b,c,d=http.request{url=""}