Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[patch] Fix condition that sets cert_manager_cluster_resource_namespace #1156

Merged
merged 1 commit into from
Jan 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ibm/mas_devops/common_tasks/detect_cert_manager.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
set_fact:
cert_manager_namespace: "{{ cert_manager_webhook_lookup.stdout }}"

# If 'cert_manager_cluster_resource_namespace' is not yet defined then set it to same value as 'cert_manager_namespace'
- name: Set Certificate Manager Cluster Resource namespace (if not set)
set_fact:
cert_manager_cluster_resource_namespace: "{{ cert_manager_namespace }}"
Expand Down
3 changes: 2 additions & 1 deletion ibm/mas_devops/roles/suite_dns/tasks/run.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
# -----------------------------------------------------------------------------
# Ensure cert manager is installed prior continuing as this role will install
# v1alpha1.acme.cis.ibm.com apiservice which requires cert manager to be running
- include_tasks: "{{ role_path }}/../../common_tasks/detect_cert_manager.yml"
- name: Detect Certificate Manager installation
include_tasks: "{{ role_path }}/../../common_tasks/detect_cert_manager.yml"
when: cert_manager_namespace is not defined or cert_manager_namespace | length == 0

# 2. Run provider task
Expand Down
6 changes: 4 additions & 2 deletions ibm/mas_devops/roles/suite_install/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,9 @@

# 4. Determine version of cert-manager in use on the cluster
# -----------------------------------------------------------------------------
- include_tasks: "{{ role_path }}/../../common_tasks/detect_cert_manager.yml"
when: cert_manager_namespace is not defined or cert_manager_namespace | length == 0
- name: Detect Certificate Manager installation
include_tasks: "{{ role_path }}/../../common_tasks/detect_cert_manager.yml"
when: cert_manager_cluster_resource_namespace is not defined or cert_manager_cluster_resource_namespace != ''

# 5. Provide debug information
# -----------------------------------------------------------------------------
Expand All @@ -159,6 +160,7 @@
- "MAS domain .................... {{ mas_domain }}"
- "MAS ICR cp content ............ {{ mas_icr_cp }}"
- "MAS ICR cpopen content ........ {{ mas_icr_cpopen }}"
- "Cert Manager namespace ........ {{ cert_manager_cluster_resource_namespace }}"
- "MAS Cluster Issuer ............ {{ mas_cluster_issuer }}"
- "IPv6 Enabled .................. {{ enable_ipv6 }}"

Expand Down
Loading