之前在研究frp如何使用时报错
error unmarshaling JSON: while decoding JSON: json: cannot unmarshal string into Go value of type v1.ServerConfig
不知道为什么,查了半天才知道原因,原来是因为frp0.53.2版本中配置文件是按照json格式编写的,如果是字符串格式的值是需要加双引号的,否则会报错。
比如:frps.toml配置文件中
vhostHTTPPort = 8080
bind_addr = “XXX.XXX.XXX.XXX”
bindPort = 7000
webServer.addr = “127.0.0.1”
webServer.port = 7500
webServer.user = “admin”
webServer.password = “admin”
log.to = “./frps.log”
log.level = “info”
log.maxDays = 3
bind_addr这种ip地址就是字符串,是必须加双引号的,如果不加,在启动frps时就会报错误,如下图。
将ip地址加上双引号后,再执行就可以正常启动了。
原文地址:https://blog.csdn.net/scottchenrui2017/article/details/135400985
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。