Files
cameleer-server/deploy/opensearch.yaml
hsiegeln c346babe33
All checks were successful
CI / build (pull_request) Successful in 1m9s
CI / docker (pull_request) Has been skipped
CI / deploy (pull_request) Has been skipped
fix: correct PostgreSQL mountPath and add external NodePort services
- Fix postgres.yaml mountPath to /home/postgres/pgdata matching timescaledb-ha PGDATA
- Add NodePort services for external access: PostgreSQL (30432), OpenSearch (30920)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 01:00:20 +01:00

99 lines
2.1 KiB
YAML

apiVersion: apps/v1
kind: StatefulSet
metadata:
name: opensearch
namespace: cameleer
spec:
serviceName: opensearch
replicas: 1
selector:
matchLabels:
app: opensearch
template:
metadata:
labels:
app: opensearch
spec:
containers:
- name: opensearch
image: opensearchproject/opensearch:2.19.0
ports:
- containerPort: 9200
name: http
- containerPort: 9300
name: transport
env:
- name: discovery.type
value: single-node
- name: DISABLE_SECURITY_PLUGIN
value: "true"
volumeMounts:
- name: data
mountPath: /usr/share/opensearch/data
resources:
requests:
memory: "1Gi"
cpu: "200m"
limits:
memory: "4Gi"
cpu: "1000m"
livenessProbe:
exec:
command:
- sh
- -c
- curl -s http://localhost:9200/_cluster/health
initialDelaySeconds: 30
periodSeconds: 10
timeoutSeconds: 5
failureThreshold: 3
readinessProbe:
exec:
command:
- sh
- -c
- curl -s http://localhost:9200/_cluster/health
initialDelaySeconds: 15
periodSeconds: 10
timeoutSeconds: 5
failureThreshold: 3
volumeClaimTemplates:
- metadata:
name: data
spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: 10Gi
---
apiVersion: v1
kind: Service
metadata:
name: opensearch
namespace: cameleer
spec:
clusterIP: None
selector:
app: opensearch
ports:
- port: 9200
targetPort: 9200
name: http
- port: 9300
targetPort: 9300
name: transport
---
apiVersion: v1
kind: Service
metadata:
name: opensearch-external
namespace: cameleer
spec:
type: NodePort
selector:
app: opensearch
ports:
- port: 9200
targetPort: 9200
nodePort: 30920