summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kubernetes/aai/components/aai-graphadmin/templates/job-copy-db-backup.yaml4
-rw-r--r--kubernetes/aai/components/aai-graphadmin/templates/job-create-db.yaml4
-rw-r--r--kubernetes/aai/components/aai-graphadmin/templates/job-migration.yaml4
-rw-r--r--kubernetes/aai/components/aai-graphadmin/values.yaml2
-rw-r--r--kubernetes/common/cassandra/values.yaml3
-rw-r--r--kubernetes/common/common/templates/_cassOp.tpl10
-rw-r--r--kubernetes/sdc/components/sdc-cs/templates/job.yaml4
7 files changed, 24 insertions, 7 deletions
diff --git a/kubernetes/aai/components/aai-graphadmin/templates/job-copy-db-backup.yaml b/kubernetes/aai/components/aai-graphadmin/templates/job-copy-db-backup.yaml
index 865dfe3eeb..2bee19ffcf 100644
--- a/kubernetes/aai/components/aai-graphadmin/templates/job-copy-db-backup.yaml
+++ b/kubernetes/aai/components/aai-graphadmin/templates/job-copy-db-backup.yaml
@@ -64,7 +64,11 @@ spec:
- command:
- /bin/bash
- -c
+ {{- if .Values.global.cassandra.useOperator }}
+ - /app/ready.py --app-name aai-cassandra-reaper --timeout 1 || /app/ready.py --app-name cassandra-reaper
+ {{- else }}
- /app/ready.py --app-name aai-cassandra --timeout 1 || /app/ready.py --app-name cassandra
+ {{- end }}
env:
- name: NAMESPACE
valueFrom:
diff --git a/kubernetes/aai/components/aai-graphadmin/templates/job-create-db.yaml b/kubernetes/aai/components/aai-graphadmin/templates/job-create-db.yaml
index 1a8124929f..c80d348e32 100644
--- a/kubernetes/aai/components/aai-graphadmin/templates/job-create-db.yaml
+++ b/kubernetes/aai/components/aai-graphadmin/templates/job-create-db.yaml
@@ -60,9 +60,9 @@ spec:
args:
- --app-name
{{- if .Values.global.cassandra.localCluster }}
- - aai-cassandra
+ - {{ ternary "aai-cassandra-reaper" "aai-cassandra" .Values.global.cassandra.useOperator }}
{{- else }}
- - cassandra
+ - {{ ternary "cassandra-reaper" "cassandra" .Values.global.cassandra.useOperator }}
{{- end }}
- --container-name
- aai-schema-service
diff --git a/kubernetes/aai/components/aai-graphadmin/templates/job-migration.yaml b/kubernetes/aai/components/aai-graphadmin/templates/job-migration.yaml
index bf3279fde7..b2bc0e735e 100644
--- a/kubernetes/aai/components/aai-graphadmin/templates/job-migration.yaml
+++ b/kubernetes/aai/components/aai-graphadmin/templates/job-migration.yaml
@@ -65,9 +65,9 @@ spec:
args:
- --app-name
{{- if .Values.global.cassandra.localCluster }}
- - aai-cassandra
+ - {{ ternary "aai-cassandra-reaper" "aai-cassandra" .Values.global.cassandra.useOperator }}
{{- else }}
- - cassandra
+ - {{ ternary "cassandra-reaper" "cassandra" .Values.global.cassandra.useOperator }}
{{- end }}
- --container-name
- aai-schema-service
diff --git a/kubernetes/aai/components/aai-graphadmin/values.yaml b/kubernetes/aai/components/aai-graphadmin/values.yaml
index e354671f94..09396cc104 100644
--- a/kubernetes/aai/components/aai-graphadmin/values.yaml
+++ b/kubernetes/aai/components/aai-graphadmin/values.yaml
@@ -28,6 +28,8 @@ global: # global defaults
cassandra:
#This will instantiate AAI cassandra cluster, default:shared cassandra.
localCluster: false
+ # flag to enable the DB creation via k8ssandra-operator
+ useOperator: true
initContainers:
enabled: true
jobs:
diff --git a/kubernetes/common/cassandra/values.yaml b/kubernetes/common/cassandra/values.yaml
index 930fe9b2d3..eef716eae6 100644
--- a/kubernetes/common/cassandra/values.yaml
+++ b/kubernetes/common/cassandra/values.yaml
@@ -41,7 +41,8 @@ k8ssandraOperator:
casOptions:
authorizer: AllowAllAuthorizer
jvmOptions:
- heapSize: 512M
+ heap_initial_size: 512M
+ heap_max_size: 4096M
hostNetwork: false
datacenters:
- name: dc1
diff --git a/kubernetes/common/common/templates/_cassOp.tpl b/kubernetes/common/common/templates/_cassOp.tpl
index d0f23877a4..3ea3ff17d0 100644
--- a/kubernetes/common/common/templates/_cassOp.tpl
+++ b/kubernetes/common/common/templates/_cassOp.tpl
@@ -24,16 +24,26 @@ metadata:
name: {{ .Values.k8ssandraOperator.config.clusterName }}
spec:
reaper:
+ initContainerImage:
+ registry: {{ include "repositoryGenerator.dockerHubRepository" . }}
containerImage:
registry: {{ include "repositoryGenerator.dockerHubRepository" . }}
autoScheduling:
enabled: true
+ metadata:
+ commonLabels:
+ app: {{ .Values.k8ssandraOperator.config.clusterName }}-reaper
+ version: {{ .Values.k8ssandraOperator.cassandraVersion }}
stargate:
containerImage:
registry: {{ include "repositoryGenerator.dockerHubRepository" . }}
tag: {{ .Values.k8ssandraOperator.stargate.tag }}
size: {{ .Values.k8ssandraOperator.stargate.size }}
heapSize: {{ .Values.k8ssandraOperator.stargate.jvmOptions.heapSize }}
+ metadata:
+ commonLabels:
+ app: {{ .Values.k8ssandraOperator.config.clusterName }}-stargate
+ version: {{ .Values.k8ssandraOperator.cassandraVersion }}
livenessProbe:
initialDelaySeconds: 200
periodSeconds: 10
diff --git a/kubernetes/sdc/components/sdc-cs/templates/job.yaml b/kubernetes/sdc/components/sdc-cs/templates/job.yaml
index 3738ff4a22..80820544d8 100644
--- a/kubernetes/sdc/components/sdc-cs/templates/job.yaml
+++ b/kubernetes/sdc/components/sdc-cs/templates/job.yaml
@@ -36,9 +36,9 @@ spec:
args:
- --app-name
{{- if .Values.global.sdc_cassandra.localCluster }}
- - sdc-cs
+ - {{ ternary "sdc-cs-reaper" "sdc-cs" .Values.global.sdc_cassandra.useOperator }}
{{- else }}
- - cassandra
+ - {{ ternary "cassandra-reaper" "cassandra" .Values.global.sdc_cassandra.useOperator }}
{{- end }}
- "-t"
- "15"