Skip to content

Commit

Permalink
Debug helm mysql installation
Browse files Browse the repository at this point in the history
  • Loading branch information
Carlos Gonzalez committed Nov 21, 2024
1 parent 00e137e commit 0cb0608
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 20 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ lint: install
test dependency create prepare converge idempotence side-effect verify destroy login reset list:
KIND_RELEASE=$(KIND_RELEASE) \
K8S_RELEASE=$(K8S_RELEASE) \
ANSIBLE_DEBUG=True ANSIBLE_VERBOSITY=5 poetry run molecule $@ -s ${MOLECULE_SCENARIO}
poetry run molecule $@ -s ${MOLECULE_SCENARIO}

rebuild: destroy prepare create

Expand Down
61 changes: 42 additions & 19 deletions tasks/deploy/mysql.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,43 @@
---
- name: Deploy bitnami MySQL chart
kubernetes.core.helm:
name: "{{ _chart_name }}"
chart_ref: "{{ k8s_mysql_chart.repo }}"
chart_version: "{{ _release }}"
release_namespace: "{{ item.namespace }}"
create_namespace: true
state: present
wait: true
wait_timeout: "{{ k8s_mysql_wait_timeout }}s"
kubeconfig: "{{ k8s_kubeconfig | default(omit) }}"
binary_path: "{{ k8s_helm_bin | default(omit) }}"
values: "{{ item.parameters }}"
vars:
_release: "{{ k8s_mysql_chart_release | default(k8s_mysql_chart.release) }}"
_chart_name: "{{ item.name }}"
loop: "{{ k8s_mysql_deployments }}"
loop_control:
label: "{{ _chart_name }}"
- block:

Check failure on line 2 in tasks/deploy/mysql.yml

View workflow job for this annotation

GitHub Actions / lint

name[missing]

All tasks should be named.
- name: Deploy bitnami MySQL chart
kubernetes.core.helm:
name: "{{ _chart_name }}"
chart_ref: "{{ k8s_mysql_chart.repo }}"
chart_version: "{{ _release }}"
release_namespace: "{{ item.namespace }}"
create_namespace: true
state: present
wait: true
wait_timeout: "150"
kubeconfig: "{{ k8s_kubeconfig | default(omit) }}"
binary_path: "{{ k8s_helm_bin | default(omit) }}"
values: "{{ item.parameters }}"
vars:
_release: "{{ k8s_mysql_chart_release | default(k8s_mysql_chart.release) }}"
_chart_name: "{{ item.name }}"
loop: "{{ k8s_mysql_deployments }}"
loop_control:
label: "{{ _chart_name }}"

rescue:
- name: Gather mysql pods
kubernetes.core.k8s_info:
kind: Pod
register: k8s_output

- name: Gather information about test-chart with pending state
kubernetes.core.helm_info:
name: molecule
release_namespace: mysql
release_state:
- all
register: helm_output

- debug:

Check failure on line 37 in tasks/deploy/mysql.yml

View workflow job for this annotation

GitHub Actions / lint

fqcn[action-core]

Use FQCN for builtin module actions (debug).

Check failure on line 37 in tasks/deploy/mysql.yml

View workflow job for this annotation

GitHub Actions / lint

name[missing]

All tasks should be named.
msg: "{{ k8s_output }}"

- debug:

Check failure on line 40 in tasks/deploy/mysql.yml

View workflow job for this annotation

GitHub Actions / lint

fqcn[action-core]

Use FQCN for builtin module actions (debug).

Check failure on line 40 in tasks/deploy/mysql.yml

View workflow job for this annotation

GitHub Actions / lint

name[missing]

All tasks should be named.
msg: "{{ helm_output }}"

- fail:

Check failure on line 43 in tasks/deploy/mysql.yml

View workflow job for this annotation

GitHub Actions / lint

fqcn[action-core]

Use FQCN for builtin module actions (fail).

Check failure on line 43 in tasks/deploy/mysql.yml

View workflow job for this annotation

GitHub Actions / lint

name[missing]

All tasks should be named.

0 comments on commit 0cb0608

Please sign in to comment.