fix automouting of gluster mounts on home

This commit is contained in:
2022-10-05 18:44:44 -04:00
parent 58f00230a3
commit 10dbe924ad
9 changed files with 119 additions and 22 deletions

View File

@@ -0,0 +1,51 @@
---
#https://github.com/bitnami/charts/tree/master/bitnami/mariadb
- name: "todo: deploy mariadb"
debug:
msg: "TODO: write deployment tasks"
- name: Create a namespace for mariadb
k8s:
kubeconfig: "/etc/rancher/k3s/k3s.yaml"
name: mariadb
api_version: v1
kind: Namespace
state: present
become: true
- name: create persistent volume resources
kubernetes.core.k8s:
kubeconfig: "/etc/rancher/k3s/k3s.yaml"
state: present
definition: "{{ lookup('template', item) | from_yaml }}"
loop:
- mariadb/pv.yaml
- mariadb/pv-claim.yaml
become: true
- name: Install mariadb globally available
block:
- name: Add mariadb chart helm repo
local_action:
module: kubernetes.core.helm_repository
name: bitnami
repo_url: https://charts.bitnami.com/bitnami
- name: load variables files/mariadb/values.yaml
ansible.builtin.include_vars:
file: files/mariadb/values.yaml
name: stash_values
- name: Install mariadb Release
local_action:
module: kubernetes.core.helm
release_state: present
name: "{{apps.mariadb.namespace}}"
namespace: mariadb
create_namespace: yes
update_repo_cache: True
chart_ref: bitnami/mariadb
values: "{{stash_values}}"
wait: true