Integrating catalog

This commit is contained in:
plm 2025-01-10 16:41:41 +01:00
parent fb5aed882f
commit 0b362983a3
5 changed files with 94 additions and 1 deletions

View File

@ -303,6 +303,18 @@ ocWorkflow:
cpu: "128m" cpu: "128m"
memory: "256Mi" memory: "256Mi"
ocCatalog:
enabled: true
image: oc/oc-catalog:0.0.1
resources:
limits:
cpu: "128m"
memory: "256Mi"
requests:
cpu: "128m"
memory: "256Mi"
loki: loki:
enabled: false enabled: false

View File

@ -0,0 +1,35 @@
{{- if index .Values.ocCatalog.enabled }}
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: oc-catalog
name: {{ .Release.Name }}-oc-catalog
spec:
replicas: 1
selector:
matchLabels:
app: oc-catalog
template:
metadata:
labels:
app: oc-catalog
spec:
containers:
- image: "{{ .Values.ocCatalog.image }}"
name: oc-catalog
envFrom:
- configMapRef:
name: opencloud-config
ports:
- name: http
containerPort: 8080
protocol: TCP
resources:
limits:
cpu: "{{ .Values.ocCatalog.resources.limits.cpu }}"
memory: "{{ .Values.ocCatalog.resources.limits.memory }}"
requests:
cpu: "{{ .Values.ocCatalog.resources.requests.cpu }}"
memory: "{{ .Values.ocCatalog.resources.requests.memory }}"
{{- end }}

View File

@ -0,0 +1,29 @@
{{- if index .Values.ocCatalog.enabled }}
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: oc-catalog-ingress
spec:
entryPoints:
- web
routes:
- kind: Rule
match: Host(`{{ .Values.host }}`) && PathPrefix(`/catalog`)
priority: 10
services:
- kind: Service
name: oc-catalog-svc
port: 8080
middlewares:
- name: strip-catalog-prefix
---
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: strip-catalog-prefix
spec:
stripPrefix:
prefixes:
- "/catalog"
{{- end }}

View File

@ -0,0 +1,17 @@
{{- if index .Values.ocCatalog.enabled }}
apiVersion: v1
kind: Service
metadata:
name: oc-catalog-svc
labels:
app: oc-catalog-svc
spec:
ports:
- name: http
port: 8080
protocol: TCP
targetPort: 8080
selector:
app: oc-catalog
type: ClusterIP
{{- end }}

View File

@ -8,7 +8,7 @@ data:
{ {
"WORKSPACE_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/workspace/oc", "WORKSPACE_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/workspace/oc",
"WORKFLOW_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/workflow/oc", "WORKFLOW_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/workflow/oc",
"ITEM_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/item/oc", "ITEM_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/catalog/oc",
"SCHEDULER_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/scheduler/oc", "SCHEDULER_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/scheduler/oc",
"LOGS_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/logs", "LOGS_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/logs",
"PEER_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/peers/oc", "PEER_HOST": "{{ .Values.scheme }}://{{ .Values.host }}/peers/oc",