Casbin adapter implementation using Minio/AWS S3 policy storage
go get github.com/Soluto/casbin-minio-adapter
import (
minioadapter "github.com/Soluto/casbin-minio-adapter"
"github.com/casbin/casbin"
)
func main() {
adapter, _ := minioadapter.NewAdapter("http://minio-endpoint", "accessKey", "secretKey", false, "casbin-bucker", "policy.csv")
enforcer := casbin.NewSyncedEnforcer("rbac_model.conf", adapter)
}
For real-world example visit Tweek.
This project is under MIT License. See the LICENSE file for the full license text.