const rp = require('request-promise'),
tnl = require('tunnel'),
url = 'https://google.ru';
let tunnel = tnl.httpsOverHttp({
proxy: {
host: 'x.x.x.x',
port: x
}
});
rp({
url: url,
method: 'GET',
headers: {
'User-Agent': 'Node js'
},
agent: tunnel,
resolveWithFullResponse: true,
timeout: 10000,
followRedirect: true,
maxRedirects: 10,
strictSSL: false
})
.then(response => {
console.log(response);
});
При запуске выдает Error: tunneling socket could not be established, cause=connect ETIMEDOUT
Как это пофиксить? Прочекал уже кучу подобных вопросов, но ничего не помогает. Прокси юзаю валидные.