Skip to content

Commit

Permalink
Merge branch 'master' into raz/per-8584-fix-opal-helm-chart-linting
Browse files Browse the repository at this point in the history
  • Loading branch information
RazcoDev authored Dec 18, 2023
2 parents 694fe9f + f027a36 commit 513d16c
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ type: application
icon: https://www.opal.ac/icons/icon-192x192.png
version: 0.0.0 # actual chart version is managed by git tags
kubeVersion: ">= 1.18.0-0"
appVersion: 0.7.3
appVersion: 0.7.4
7 changes: 6 additions & 1 deletion templates/deployment-client.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ spec:
containers:
- name: opal-client
image: {{ include "opal.clientImage" . | quote }}
imagePullPolicy: IfNotPresent
imagePullPolicy: {{ .Values.client.imagePullPolicy | default "IfNotPresent" | quote }}
ports:
- name: http
containerPort: {{ .Values.client.port }}
Expand All @@ -43,8 +43,13 @@ spec:
- name: UVICORN_NUM_WORKERS
value: "1"
{{- if .Values.server }}
{{- if .Values.client.serverUrl }}
- name: OPAL_SERVER_URL
value: {{ .Values.client.serverUrl | quote }}
{{- else }}
- name: OPAL_SERVER_URL
value: {{ printf "http://%s:%v" (include "opal.serverName" .) .Values.server.port | quote }}
{{- end}}
{{- if not (or (.Values.server.dataConfigSources.external_source_url) (.Values.server.dataConfigSources.config) (hasKey .Values.client.extraEnv "OPAL_DATA_UPDATER_ENABLED") ) }}
- name: OPAL_DATA_UPDATER_ENABLED
value: "False"
Expand Down
2 changes: 1 addition & 1 deletion templates/deployment-server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ spec:
containers:
- name: opal-server
image: {{ include "opal.serverImage" . | quote }}
imagePullPolicy: IfNotPresent
imagePullPolicy: {{ .Values.server.imagePullPolicy | default "IfNotPresent" | quote }}
{{- if .Values.e2e }}
volumeMounts:
- mountPath: /opt/e2e/policy-repo-data
Expand Down
14 changes: 14 additions & 0 deletions values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,11 @@
"type": "object",
"title": "resources",
"default": null
},
"imagePullPolicy": {
"type": "string",
"default": "IfNotPresent",
"title": "when kubelet should pull specified image"
}
}
},
Expand All @@ -194,6 +199,10 @@
"opaStartupData": {
"type": "object", "title": "client startup data for embedded opa", "default": null
},
"serverUrl": {
"type": "string",
"title": "opal server url for client to connect to"
},
"secrets": {
"type": "array",
"title": "name of a kubernetes secret from where to fetch secret environment variables.",
Expand All @@ -204,6 +213,11 @@
"type": "object",
"title": "resources",
"default": null
},
"imagePullPolicy": {
"type": "string",
"default": "IfNotPresent",
"title": "when kubelet should pull specified image"
}
}
}
Expand Down
4 changes: 3 additions & 1 deletion values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ server:
# external_source_url: "https://your-api.com/path/to/api/endpoint"

# Option #3 - Example static data sources (endpoint is empty by default)
# config:
# config:
# entries:
# - url: http://opal-server:7002/policy-data
# topics: ["policy_data"]
Expand All @@ -47,4 +47,6 @@ client:
port: 7000
opaPort: 8181
replicas: 1
# If you need to specify a custom hostname for the opal-sever, configure the serverUrl property
# serverUrl: http://custom-hostname-for-opal:opal-port
extraEnv: {}

0 comments on commit 513d16c

Please sign in to comment.