Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func OsloPolicy2Rego ¶
OsloPolicy2Rego takes a yaml or JSON string containing oslo.policy rules and converts them into Rego language.
It takes the packageName as the first argument, which should be a string that consists of ascii letters and numbers, with periods. This will represent the name of the package in OPA, and will be persisted to the URL that will be used for doing queries.
For example, if you pass "openstack.policy" as a packageName, the resulting package name will be "openstack.policy". Subsequently you'll be able to query: http://<OPA URL>/v1/data/openstack/policy/allow
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.