标题:请教一个网站反代的问题
作者:2722486
原帖:https://hostloc.com/thread-964970-1-1.html
摘要:网站放在荷兰小鸡上,用香港轻量小鸡1G1H30M反代荷兰小鸡2H2G
每次打开网站都很慢偶尔504,但是打开两个小鸡的宝塔面板负载都正常的呀
两个小鸡之间互ping也才200ms多的延迟,没有丢包现象
请教大佬们,那为什么打开网站会很慢?
作者:2722486
原帖:https://hostloc.com/thread-964970-1-1.html
摘要:网站放在荷兰小鸡上,用香港轻量小鸡1G1H30M反代荷兰小鸡2H2G
每次打开网站都很慢偶尔504,但是打开两个小鸡的宝塔面板负载都正常的呀
两个小鸡之间互ping也才200ms多的延迟,没有丢包现象
请教大佬们,那为什么打开网站会很慢?
标题:有没有一起折腾freefr的啊
作者:beiniceing
原帖:https://hostloc.com/thread-964971-1-1.html
摘要:目前测试zblog、wordpress均正常
卡在cloudflaze的反代了
作者:beiniceing
原帖:https://hostloc.com/thread-964971-1-1.html
摘要:目前测试zblog、wordpress均正常
卡在cloudflaze的反代了
标题:55出爱奇艺年费会员【换绑】
作者:巴黎圣日耳曼
原帖:https://hostloc.com/thread-964975-1-1.html
摘要:本帖最后由 巴黎圣日耳曼 于 2022-1-30 12:12 编辑
tg找我就行,换绑哈,不是直冲
作者:巴黎圣日耳曼
原帖:https://hostloc.com/thread-964975-1-1.html
摘要:本帖最后由 巴黎圣日耳曼 于 2022-1-30 12:12 编辑
tg找我就行,换绑哈,不是直冲
标题:【小白求助】cloudflaze反代替换文本
作者:beiniceing
原帖:https://hostloc.com/thread-964977-1-1.html
摘要:这是我所填写的内容 // 代理网站.
const upstream = 'remy.levayer.free.fr'
// 代理网站的目录.
const upstream_path = '/zblog/'
// 手机用户代理网站.
const upstream_mobile = 'remy.levayer.free.fr'
// 屏蔽国家和地区.
const blocked_region = ['']
// 屏蔽 IP 地址.
const blocked_ip_address = ['0.0.0.0', '127.0.0.1']
// 源站是否开启 HTTPS.
const https = false
// 文本替换.
const replace_dict = {
'$upstream': '$custom_domain',
'//remy.levayer.free.fr': ''
}
addEventListener('fetch', event => {
event.respondWith(fetchAndApply(event.request));
})
async function fetchAndApply(request) {
const region = request.headers.get('cf-ipcountry').toUpperCase();
const ip_address = request.headers.get('cf-connecting-ip');
const user_agent = request.headers.get('user-agent');
let response = null;
let url = new URL(request.url);
let url_hostname = url.hostname;
if (https == true) {
url.protocol = 'https:';
} else {
url.protocol = 'http:';
}
if (await device_status(user_agent)) {
var upstream_domain = upstream;
} else {
var upstream_domain = upstream_mobile;
}
url.host = upstream_domain;
if (url.pathname == '/') {
url.pathname = upstream_path;
} else {
url.pathname = upstream_path + url.pathname;
}
if (blocked_region.includes(region)) {
response = new Response('Access denied: WorkersProxy is not available in your region yet.', {
status: 403
});
} else if (blocked_ip_address.includes(ip_address)) {
response = new Response('Access denied: Your IP address is blocked by WorkersProxy.', {
status: 403
});
} else {
let method = request.method;
let request_headers = request.headers;
let new_request_headers = new Headers(request_headers);
new_request_headers.set('Host', url.hostname);
new_request_headers.set('Referer', url.hostname);
let original_response = await fetch(url.href, {
method: method,
headers: new_request_headers
})
let original_response_clone = original_response.clone();
let original_text = null;
let response_headers = original_response.headers;
let new_response_headers = new Headers(response_headers);
let status = original_response.status;
new_response_headers.set('access-control-allow-origin', '*');
new_response_headers.set('access-control-allow-credentials', true);
new_response_headers.delete('content-security-policy');
new_response_headers.delete('content-security-policy-report-only');
new_response_headers.delete('clear-site-data');
const content_type = new_response_headers.get('content-type');
if (content_type.includes('text/html') && content_type.includes('UTF-8')) {
original_text = await replace_response_text(original_response_clone, upstream_domain, url_hostname);
} else {
original_text = original_response_clone.body
}
response = new Response(original_text, {
status,
headers: new_response_headers
})
}
return response;
}
async function replace_response_text(response, upstream_domain, host_name) {
let text = await response.text()
var i, j;
for (i in replace_dict) {
j = replace_dict
if (i == '$upstream') {
i = upstream_domain
} else if (i == '$custom_domain') {
i = host_name
}
if (j == '$upstream') {
j = upstream_domain
} else if (j == '$custom_domain') {
j = host_name
}
let re = new RegExp(i, 'g')
text = text.replace(re, j);
}
return text;
}
async function device_status(user_agent_info) {
...
作者:beiniceing
原帖:https://hostloc.com/thread-964977-1-1.html
摘要:这是我所填写的内容 // 代理网站.
const upstream = 'remy.levayer.free.fr'
// 代理网站的目录.
const upstream_path = '/zblog/'
// 手机用户代理网站.
const upstream_mobile = 'remy.levayer.free.fr'
// 屏蔽国家和地区.
const blocked_region = ['']
// 屏蔽 IP 地址.
const blocked_ip_address = ['0.0.0.0', '127.0.0.1']
// 源站是否开启 HTTPS.
const https = false
// 文本替换.
const replace_dict = {
'$upstream': '$custom_domain',
'//remy.levayer.free.fr': ''
}
addEventListener('fetch', event => {
event.respondWith(fetchAndApply(event.request));
})
async function fetchAndApply(request) {
const region = request.headers.get('cf-ipcountry').toUpperCase();
const ip_address = request.headers.get('cf-connecting-ip');
const user_agent = request.headers.get('user-agent');
let response = null;
let url = new URL(request.url);
let url_hostname = url.hostname;
if (https == true) {
url.protocol = 'https:';
} else {
url.protocol = 'http:';
}
if (await device_status(user_agent)) {
var upstream_domain = upstream;
} else {
var upstream_domain = upstream_mobile;
}
url.host = upstream_domain;
if (url.pathname == '/') {
url.pathname = upstream_path;
} else {
url.pathname = upstream_path + url.pathname;
}
if (blocked_region.includes(region)) {
response = new Response('Access denied: WorkersProxy is not available in your region yet.', {
status: 403
});
} else if (blocked_ip_address.includes(ip_address)) {
response = new Response('Access denied: Your IP address is blocked by WorkersProxy.', {
status: 403
});
} else {
let method = request.method;
let request_headers = request.headers;
let new_request_headers = new Headers(request_headers);
new_request_headers.set('Host', url.hostname);
new_request_headers.set('Referer', url.hostname);
let original_response = await fetch(url.href, {
method: method,
headers: new_request_headers
})
let original_response_clone = original_response.clone();
let original_text = null;
let response_headers = original_response.headers;
let new_response_headers = new Headers(response_headers);
let status = original_response.status;
new_response_headers.set('access-control-allow-origin', '*');
new_response_headers.set('access-control-allow-credentials', true);
new_response_headers.delete('content-security-policy');
new_response_headers.delete('content-security-policy-report-only');
new_response_headers.delete('clear-site-data');
const content_type = new_response_headers.get('content-type');
if (content_type.includes('text/html') && content_type.includes('UTF-8')) {
original_text = await replace_response_text(original_response_clone, upstream_domain, url_hostname);
} else {
original_text = original_response_clone.body
}
response = new Response(original_text, {
status,
headers: new_response_headers
})
}
return response;
}
async function replace_response_text(response, upstream_domain, host_name) {
let text = await response.text()
var i, j;
for (i in replace_dict) {
j = replace_dict
if (i == '$upstream') {
i = upstream_domain
} else if (i == '$custom_domain') {
i = host_name
}
if (j == '$upstream') {
j = upstream_domain
} else if (j == '$custom_domain') {
j = host_name
}
let re = new RegExp(i, 'g')
text = text.replace(re, j);
}
return text;
}
async function device_status(user_agent_info) {
...
标题:有没有pt自动下载free种,自动删种 的教程
作者:花样
原帖:https://hostloc.com/thread-964979-1-1.html
摘要:看大佬一个月十几,几十T的上传,很是羡慕,
搞了好几年了,我也才几十T的上传,
都是纯手动,隔一阵子就上去看看有没有免费的大包,别的都不敢下,
求个全自动的教程,自动下载free种子,自动到期删种的,
自己搜索不到合适的
作者:花样
原帖:https://hostloc.com/thread-964979-1-1.html
摘要:看大佬一个月十几,几十T的上传,很是羡慕,
搞了好几年了,我也才几十T的上传,
都是纯手动,隔一阵子就上去看看有没有免费的大包,别的都不敢下,
求个全自动的教程,自动下载free种子,自动到期删种的,
自己搜索不到合适的
标题:aws HK 移动延迟很低
作者:wjbdada
原帖:https://hostloc.com/thread-964980-1-1.html
摘要:老早听说aws hk 绕的很,今天试了下,移动30-70的延迟
作者:wjbdada
原帖:https://hostloc.com/thread-964980-1-1.html
摘要:老早听说aws hk 绕的很,今天试了下,移动30-70的延迟
标题:1300收一个stripe企业号
作者:n3n3
原帖:https://hostloc.com/thread-964981-1-1.html
摘要:带资料的来,最好是带alipay的,设置了仅回帖可见,有意老哥留下联系方式
作者:n3n3
原帖:https://hostloc.com/thread-964981-1-1.html
摘要:带资料的来,最好是带alipay的,设置了仅回帖可见,有意老哥留下联系方式
标题:想搞个国外的网盘 用来自动备份网站数据 有啥免费的方案?
作者:maowenjie
原帖:https://hostloc.com/thread-964982-1-1.html
摘要:各位大佬
想搞个国外的网盘 用来自动备份网站数据 有啥免费的方案?
作者:maowenjie
原帖:https://hostloc.com/thread-964982-1-1.html
摘要:各位大佬
想搞个国外的网盘 用来自动备份网站数据 有啥免费的方案?
标题:netcup RS2000测速
作者:truecolor
原帖:https://hostloc.com/thread-964984-1-1.html
摘要:[img]%5Burl=https://imgtu.com/i/H94CkV%5D[/url][/img]
作者:truecolor
原帖:https://hostloc.com/thread-964984-1-1.html
摘要:[img]%5Burl=https://imgtu.com/i/H94CkV%5D[/url][/img]
标题:出几个会员,有人需要嘛?
作者:jpg119
原帖:https://hostloc.com/thread-964985-1-1.html
摘要:3个月快看
3个月网易游戏超级会员
12个月芒果TV会员
12月网易严选Pro
另外游戏:
《守望先锋》传奇典藏版
送两个游戏礼包:
《新倩女幽魂》礼包
《率土之滨》礼包
价格mjj们定吧,差不多就出了
电报:surile98
作者:jpg119
原帖:https://hostloc.com/thread-964985-1-1.html
摘要:3个月快看
3个月网易游戏超级会员
12个月芒果TV会员
12月网易严选Pro
另外游戏:
《守望先锋》传奇典藏版
送两个游戏礼包:
《新倩女幽魂》礼包
《率土之滨》礼包
价格mjj们定吧,差不多就出了
电报:surile98
标题:出租ks-le 老款标配款
作者:angus1220
原帖:https://hostloc.com/thread-964988-1-1.html
摘要:出租ks-le老款标配款 2021
法国 价格115/月 不出只出租号里五个3个机
作者:angus1220
原帖:https://hostloc.com/thread-964988-1-1.html
摘要:出租ks-le老款标配款 2021
法国 价格115/月 不出只出租号里五个3个机
标题:继续出没出掉的e3
作者:nerlnsqy
原帖:https://hostloc.com/thread-964987-1-1.html
摘要:https://hostloc.com/thread-937135-1-1.html
具体信息见这个帖子
关键字:17年注册 5t 新加坡 1300
作者:nerlnsqy
原帖:https://hostloc.com/thread-964987-1-1.html
摘要:https://hostloc.com/thread-937135-1-1.html
具体信息见这个帖子
关键字:17年注册 5t 新加坡 1300
标题:mjj有《魔法满屋》资源吗
作者:1652291305
原帖:https://hostloc.com/thread-964989-1-1.html
摘要:mjj有《魔法满屋》资源吗
想看
求地址
Disney+的
作者:1652291305
原帖:https://hostloc.com/thread-964989-1-1.html
摘要:mjj有《魔法满屋》资源吗
想看
求地址
Disney+的