You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
return"", fmt.Errorf("rego file path was provided without the --enable-opa flag, please provide the --enable-opa flag") // todo, can we default to setting this flag ourselves is this better UX?
322
+
if!options.enableMiddleware {
323
+
return"", fmt.Errorf("rego file path was provided without the --enable-middleware flag, please provide the --enable-middleware flag") // todo, can we default to setting this flag ourselves is this better UX?
Copy file name to clipboardExpand all lines: docs/opa-middleware.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,9 +34,9 @@ Use the [Rego playground](https://play.openpolicyagent.org/) to fine tune your r
34
34
35
35
## Enable OPA Middleware
36
36
37
-
Once you are ready with your policy document, use the `--enable-opa` flag to tell the finch-daemon to enable the OPA middleware. The daemon will then look for the policy document provided by the `--rego-file` flag.
37
+
Once you are ready with your policy document, use the `--enable-middleware` flag to tell the finch-daemon to enable the OPA middleware. The daemon will then look for the policy document provided by the `--rego-file` flag.
38
38
39
-
Note: The `--rego-file` flag is required when `--enable-opa` is set.
39
+
Note: The `--rego-file` flag is required when `--enable-middleware` is set.
Copy file name to clipboardExpand all lines: e2e/e2e_test.go
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -26,12 +26,12 @@ var SubjectPrefix = flag.String("daemon-context-subject-prefix", "", `A string w
26
26
varPrefixedSubjectEnv=flag.String("daemon-context-subject-env", "", `Environment to add when running a prefixed subject, in the form of a string like "EXAMPLE=foo EXAMPLE2=bar"`)
27
27
28
28
funcTestRun(t*testing.T) {
29
-
ifos.Getenv("OPA_E2E") =="1" {
29
+
ifos.Getenv("MIDDLEWARE_E2E") =="1" {
30
30
runOPATests(t)
31
31
} elseifos.Getenv("TEST_E2E") =="1" {
32
32
runE2ETests(t)
33
33
} else {
34
-
t.Skip("E2E tests skipped. Set TEST_E2E=1 to run regular E2E tests or OPA_E2E=1 to run OPA middleware tests")
34
+
t.Skip("E2E tests skipped. Set TEST_E2E=1 to run regular E2E tests or MIDDLEWARE_E2E=1 to run OPA middleware tests")
0 commit comments