Merge "MariaDB chart cleanup"

This commit is contained in:
Zuul 2018-01-07 16:56:30 +00:00 committed by Gerrit Code Review
commit b685513d55
9 changed files with 42 additions and 26 deletions

View File

@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/}}
{{- if .Values.manifests.configmap_bin }}
{{- $envAll := . }}
---
apiVersion: v1
@ -25,3 +26,4 @@ data:
{{ tuple "bin/_readiness.sh.tpl" . | include "helm-toolkit.utils.template" | indent 4 }}
start.sh: |
{{ tuple "bin/_start.sh.tpl" . | include "helm-toolkit.utils.template" | indent 4 }}
{{- end }}

View File

@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/}}
{{- if .Values.manifests.configmap_etc }}
{{- $envAll := . }}
---
apiVersion: v1
@ -29,3 +30,4 @@ data:
{{ tuple "etc/_20-override.cnf.tpl" . | include "helm-toolkit.utils.template" | indent 4 }}
99-force.cnf: |
{{ tuple "etc/_99-force.cnf.tpl" . | include "helm-toolkit.utils.template" | indent 4 }}
{{- end }}

View File

@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/}}
{{- if .Values.manifests.pdb_server }}
{{- $envAll := . }}
---
apiVersion: policy/v1beta1
@ -25,3 +26,4 @@ spec:
selector:
matchLabels:
{{ tuple $envAll "mariadb" "server" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }}
{{- end }}

View File

@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/}}
{{- if .Values.manifests.secret_db }}
{{- $envAll := . }}
---
apiVersion: v1
@ -23,3 +24,4 @@ metadata:
type: Opaque
data:
MYSQL_ROOT_PASSWORD: {{ .Values.endpoints.oslo_db.auth.admin.password | b64enc }}
{{- end }}

View File

@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/}}
{{- if .Values.manifests.secret_etc }}
{{- $envAll := . }}
---
apiVersion: v1
@ -23,3 +24,4 @@ metadata:
type: Opaque
data:
admin_user.cnf: {{ tuple "secrets/_admin_user.cnf.tpl" . | include "helm-toolkit.utils.template" | b64enc }}
{{- end }}

View File

@ -16,7 +16,7 @@ limitations under the License.
# This service could be used for cluster pod discovery, though instead it's
# primarily here to allow DNS lookups of cluster pods.
{{- if .Values.manifests.service_discovery }}
{{- $envAll := . }}
---
apiVersion: v1
@ -32,3 +32,4 @@ spec:
clusterIP: None
selector:
{{ tuple $envAll "mariadb" "server" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 4 }}
{{- end }}

View File

@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/}}
{{- if .Values.manifests.service }}
{{- $envAll := . }}
---
apiVersion: v1
@ -34,3 +35,4 @@ spec:
port: {{ tuple "oslo_db" "internal" "mysql" . | include "helm-toolkit.endpoints.endpoint_port_lookup" }}
selector:
{{ tuple $envAll "mariadb" "server" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 4 }}
{{- end }}

View File

@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/}}
{{- if .Values.manifests.statefulset }}
{{- $envAll := . }}
{{- $dependencies := .Values.dependencies.mariadb }}
@ -140,3 +141,4 @@ spec:
storage: {{ .Values.volume.size }}
storageClassName: {{ .Values.volume.class_name }}
{{- end }}
{{- end }}

View File

@ -12,7 +12,15 @@
# See the License for the specific language governing permissions and
# limitations under the License.
force_bootstrap: false
images:
tags:
mariadb: docker.io/mariadb:10.1.23
dep_check: quay.io/stackanetes/kubernetes-entrypoint:v0.2.1
pull_policy: IfNotPresent
labels:
node_selector_key: openstack-control-plane
node_selector_value: enabled
pod:
affinity:
@ -30,32 +38,25 @@ pod:
resources:
enabled: false
server:
limits:
memory: "128Mi"
cpu: "500m"
requests:
memory: "128Mi"
cpu: "500m"
images:
tags:
mariadb: docker.io/mariadb:10.1.23
dep_check: quay.io/stackanetes/kubernetes-entrypoint:v0.2.1
pull_policy: IfNotPresent
cpu: "100m"
limits:
memory: "1024Mi"
cpu: "2000m"
dependencies:
mariadb:
jobs: null
services: null
force_bootstrap: false
volume:
enabled: true
class_name: general
size: 5Gi
labels:
node_selector_key: openstack-control-plane
node_selector_value: enabled
database:
config_override: null
# Any configuration here will override the base config.
@ -63,16 +64,6 @@ database:
# [mysqld]
# wsrep_slave_threads=1
resources:
enabled: false
server:
requests:
memory: "128Mi"
cpu: "100m"
limits:
memory: "1024Mi"
cpu: "2000m"
# typically overriden by environmental
# values, but should include all endpoints
# required by this chart
@ -95,3 +86,13 @@ endpoints:
default: 3306
wsrep:
default: 4567
manifests:
configmap_bin: true
configmap_etc: true
pdb_server: true
secret_db: true
secret_etc: true
service_discovery: true
service: true
statefulset: true