Skip to content

Commit

Permalink
feat: update mariadb to the latest stable release
Browse files Browse the repository at this point in the history
This change takes our build of mariadb to the latest stable release.

Co-Authored-By: Luke Repko <[email protected]>
Signed-off-by: Kevin Carter <[email protected]>
  • Loading branch information
cloudnull and LukeRepko committed Dec 21, 2024
1 parent ff70082 commit 3acdecb
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 6 deletions.
17 changes: 15 additions & 2 deletions base-kustomize/mariadb-cluster/base/mariadb-backup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,25 @@ spec:
namespace: openstack
schedule:
cron: "0 0 * * *"
serviceAccountName: backup
compression: gzip
storage:
persistentVolumeClaim:
resources:
requests:
storage: 1Gi
accessModes:
- ReadWriteOnce
securityContext:
runAsUser: 0
args:
- --single-transaction
- --all-databases
- --verbose
resources:
requests:
cpu: 100m
memory: 128Mi
limits:
cpu: 300m
memory: 512Mi
affinity:
antiAffinityEnabled: true
3 changes: 2 additions & 1 deletion base-kustomize/mariadb-cluster/base/mariadb-replication.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ spec:
generate: false
username: mariadb
database: mariadb
image: mariadb:10.11.7
image: docker-registry1.mariadb.com/library/mariadb:11.4.3

affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
Expand Down
15 changes: 12 additions & 3 deletions bin/install-mariadb-operator.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
#!/bin/bash
# shellcheck disable=SC2124,SC2145,SC2294

export VERSION="${VERSION:-0.36.0}"

# Default parameter value
CLUSTER_NAME=${1:-cluster.local}
export CLUSTER_NAME=${CLUSTER_NAME:-cluster.local}

# Directory to check for YAML files
CONFIG_DIR="/etc/genestack/helm-configs/mariadb-operator"
Expand All @@ -27,12 +29,19 @@ if [ "${CLUSTER_NAME}" != "cluster.local" ]; then
fi
fi

# Add the mariadb-operator helm repository
helm repo add mariadb-operator https://helm.mariadb.com/mariadb-operator
helm repo update

# Install the CRDs that match the version defined
helm upgrade --install mariadb-operator-crds mariadb-operator/mariadb-operator-crds --version "${VERSION}"

# Helm command setup
HELM_CMD="helm upgrade --install mariadb-operator mariadb-operator --repo https://mariadb-operator.github.io/mariadb-operator \
HELM_CMD="helm upgrade --install mariadb-operator mariadb-operator \
--namespace=mariadb-system \
--create-namespace \
--timeout 120m \
--version 0.28.1 \
--version ${VERSION} \
--post-renderer /etc/genestack/kustomize/kustomize.sh \
--post-renderer-args mariadb-operator/overlay \
-f /opt/genestack/base-helm-configs/mariadb-operator/mariadb-operator-helm-overrides.yaml"
Expand Down

0 comments on commit 3acdecb

Please sign in to comment.