"open ./permission/rbac_models.conf: The system cannot find the path specified."

引入相对文件报错 "open ./permission/rbac_models.conf: The system cannot find the path specified."

casbin.NewEnforcer("./permission/rbac_models.conf", a)
修改为

 

 

MyEnforcer, err = casbin.NewEnforcer("middlewares/permission/rbac_models.conf", a)
posted @ 2021-09-23 00:07  雪糕战士  阅读(230)  评论(0编辑  收藏  举报