×

注意!页面内容来自https://www.cnblogs.com/yunmuq/p/19742558,本站不储存任何内容,为了更好的阅读体验进行在线解析,若有广告出现,请及时反馈。若您觉得侵犯了您的利益,请通知我们进行删除,然后访问 原网页

小龙虾openclaw安装配置之局域网访问web页面18789

openclaw gateway解决:设置教程,解决:origin not allowed;control ui requires device identity;pairing required;(open the Control UI from the gateway host or allow it in gateway.controlUi.allowedOrigins)(use HTTPS or localhost secure context)




设置教程,解决:

origin not allowed

control ui requires device identity

pairing required

(open the Control UI from the gateway host or allow it in gateway.controlUi.allowedOrigins)

(use HTTPS or localhost secure context)




openclaw默认的防护级别很严格,web只允许本机访问,如果安装在linux、工控机、开发板上,其它设备默认无法访问

想要局域网访问你在虚拟机或者其它硬件上安装的小龙虾,推荐办法

步骤:

  1. openclaw机器防火墙开放18789端口

  2. openclaw gateway绑定0.0.0.0而不是127.0.0.1

openclash config set gateway.bind lan
# 再重启gateway
  1. 这时候能通过openclaw机器IP访问,但是登录页面报错无法登录。可以让访问端将自身的端口转发到openclaw机器18789端口,以Windows为例,以管理员身份打开终端,运行
netsh interface portproxy add v4tov4  listenaddress=127.0.0.1 listenport=18789 connectaddress=小龙虾IP  connectport=18789

# 后续查看与删除
# netsh interface portproxy show all
# netsh interface portproxy delete v4tov4  listenaddress=127.0.0.1 listenport=18789

这样一步是为了解决origin跨域问题 + 只允许HTTPS or localhost访问问题,端口转发后,Windows访问127.0.0.1:18789就相当于访问小龙虾了

  1. 浏览器访问127.0.0.1:18789,打开小龙虾页面,填入openclaw gateway token,这个token配置文件中有,或者运行openclash gateway dashboard也能出来

  2. 这时候web会报错pairing required,需要在openclaw上批准这个浏览器访问,运行

openclaw devices list

openclaw devices approve 请求id

浏览器再刷新就能登录



posted @ 2026-03-20 10:48  云牧青  阅读(3957)  评论(0)    收藏  举报