I am new to opa server. I am working on using opa as authorizer for multiple policies and use case is that I upload multiple policies to s3 bucket and then each policy has his own link like /opa/example/allow or /opa/example1/approve. Now I want to use different requests coming to use this link along with data to check whether they are allowed for specific policy or not.
I am little confused with config as I was going through opa docs. Can someone guide me for same. Following is config I am using and whenever I am hitting opa server it is giving blank response. I have taken this from some blog but not sure if it will work or not.
config.yaml
bundle-s3:
url: https://opa-testing1.s3.us-west-2.amazonaws.com/
credentials:
s3_signing:
environment_credentials: {}
inside this bucket I have a bundle with rego file as follow :
package opa.examples
import input.user
import input.method
default allow = false
allow { user = "alice" }
allow {
user = "bob"
method = "GET"
}
opa server I am running using : opa run --server -c config.yaml
Request I am hitting is on : localhost:8181/v1/data/opa/example/allow
Can someone help me how I can achieve my use case here and some blogs or examples will be very useful