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

feat: crmsh 4.6.0 support and stonith-enabled workflow update #232

Merged
merged 3 commits into from
Oct 16, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ An Ansible role for managing High Availability Clustering.

* Compatible OS
* RHEL 8.3+, Fedora 31+
* SLES 15 SP5+ with HA extension, SLES4SAP 15 SP5+
* SUSE Linux Enterprise Server 15 with HA extension
* SUSE Linux Enterprise Server for SAP Applications 15
* Systems running RHEL are expected to be registered and have High-Availability
repositories accessible, and ResilientStorage repositories accessible if using
`ha_cluster_enable_repos_resilient_storage`
Expand Down Expand Up @@ -153,6 +154,13 @@ It is possible to specify fence agents here as well. However,
[`ha_cluster_fence_agent_packages`](#ha_cluster_fence_agent_packages) is
preferred for that, so that its default value is overridden.

#### `ha_cluster_use_latest_packages`

boolean, default: `false`

If set to `true`, all packages will be installed with latest version.</br>
richm marked this conversation as resolved.
Show resolved Hide resolved
If set to `false`, existing packages will not be updated.

#### `ha_cluster_hacluster_password`

string, no default - must be specified
Expand Down
1 change: 1 addition & 0 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ ha_cluster_extra_packages: []
# Default fence agent packages are defined in respective os_family var files
ha_cluster_fence_agent_packages:
"{{ __ha_cluster_fence_agent_packages_default }}"
ha_cluster_use_latest_packages: false

ha_cluster_hacluster_password: ""
ha_cluster_regenerate_keys: false
Expand Down
4 changes: 2 additions & 2 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
__ha_cluster_role_essential_packages
+
ha_cluster_extra_packages }}"
state: latest
state: "{{ 'latest' if ha_cluster_use_latest_packages else 'present' }}"
use: "{{ (__ha_cluster_is_ostree | d(false)) |
ternary('ansible.posix.rhel_rpm_ostree', omit) }}"

Expand Down Expand Up @@ -73,7 +73,7 @@
ternary(__ha_cluster_cloud_agents_packages, [])
+
ha_cluster_fence_agent_packages }}"
state: latest
state: "{{ 'latest' if ha_cluster_use_latest_packages else 'present' }}"
use: "{{ (__ha_cluster_is_ostree | d(false)) |
ternary('ansible.posix.rhel_rpm_ostree', omit) }}"

Expand Down
5 changes: 2 additions & 3 deletions tasks/shell_crmsh/crm-cluster-properties.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@
ansible.builtin.set_fact:
__ha_cluster_property_attr: "{{
(properties_set.attrs + [{'name': 'stonith-enabled', 'value': 'true'}])
if properties_set.attrs | selectattr('name','equalto','stonith-enabled')
| list | length == 0
else properties_set.attrs }}"
if properties_set.attrs | selectattr('name', 'equalto', 'stonith-enabled') | list | length == 0
richm marked this conversation as resolved.
Show resolved Hide resolved
else properties_set.attrs }}" # yamllint disable-line rule:line-length
richm marked this conversation as resolved.
Show resolved Hide resolved

- name: Configure cluster properties set
ansible.builtin.command:
Expand Down
Loading