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
Both containers bundle-consumer-app and opa are up and running. I see the bundle is successfully pulled , logs: {"level":"info","msg":"Bundle loaded and activated successfully.","name":"authz","plugin":"bundle","time":"2023-04-18T06:59:57Z"}
I am sending this file as a response to download
[ policies.tar.gz
](url)
I am getting similar result when I pass the bundle directly , without bundle service.
But With Bundle I am receiving empty result. Seems like the OPA bundle is not loaded properly.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I am having this bundle services:
services:
url: http://docker.for.mac.localhost:8080/bundle-provider
bundles:
authz:
service: bundleService
resource: download/policies.tar.gz
polling:
min_delay_seconds: 10
max_delay_seconds: 20
and deployment file:
apiVersion: apps/v1
kind: Deployment
metadata:
name: bundle-consumer-app
spec:
replicas: 1
selector:
matchLabels:
app: bundle-consumer-app
template:
metadata:
labels:
app: bundle-consumer-app
name: opa
spec:
containers:
- name: bundle-consumer-app
image: bundle-consumer-app
imagePullPolicy: Never
ports:
- containerPort: 8080
- name: opa
image: openpolicyagent/opa:0.51.0
ports:
- name: http
containerPort: 8181
args:
- "run"
- "--ignore=.*" # exclude hidden dirs created by Kubernetes
- "--server"
- "--config-file"
- "/policies/bundle-config-local.yaml"
volumeMounts:
- readOnly: true
mountPath: /policies
name: policy-config
livenessProbe:
httpGet:
scheme: HTTP # assumes OPA listens on localhost:8181
port: 8181
initialDelaySeconds: 5 # tune these periods for your environment
periodSeconds: 5
readinessProbe:
httpGet:
path: /health?bundle=true # Include bundle activation in readiness
scheme: HTTP
port: 8181
initialDelaySeconds: 5
periodSeconds: 5
volumes:
- name: policy-config
configMap:
name: policy-config
Both containers bundle-consumer-app and opa are up and running. I see the bundle is successfully pulled , logs: {"level":"info","msg":"Bundle loaded and activated successfully.","name":"authz","plugin":"bundle","time":"2023-04-18T06:59:57Z"}
I am sending this file as a response to download
[
policies.tar.gz
](url)
For this curl,
curl --location 'http://localhost:8181/v1/data/play/user_is_admin' --header 'Content-Type: application/json' --data '{ "input": { "user": "yashas" } }'
I am expecting
{ "result": true }
I am getting similar result when I pass the bundle directly , without bundle service.
But With Bundle I am receiving empty result. Seems like the OPA bundle is not loaded properly.
Beta Was this translation helpful? Give feedback.
All reactions