Skip to content

Commit

Permalink
Merge pull request #933 from sap-linuxlab/dev
Browse files Browse the repository at this point in the history
merge dev to main for release 1.5.1
  • Loading branch information
berndfinger authored Jan 15, 2025
2 parents ee4f366 + 468f8ce commit a872878
Show file tree
Hide file tree
Showing 85 changed files with 793 additions and 331 deletions.
24 changes: 24 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,30 @@ community.sap_install Release Notes
.. contents:: Topics


1.5.1
Release Summary
---------------
- Release Date: 2025-01-15

This is a bugfix release of the `community.sap_install` collection.

Minor Changes
-------------
- sap_ha_pacemaker_cluster: enable Simple Mount on RHEL (https://github.com/sap-linuxlab/community.sap_install/pull/931)
- sap_ha_pacemaker_cluster/SUSE: Rework SAPHanaSR-angi pre-steps and add SLES 16 vars (https://github.com/sap-linuxlab/community.sap_install/pull/928)
- sap_swpm, sap_general_preconfigure: Add variables for sap_install FQCN collection name for calling roles (https://github.com/sap-linuxlab/community.sap_install/pull/925)
- sap_general_preconfigure: Implement SAP note 2369910 (https://github.com/sap-linuxlab/community.sap_install/pull/914)
- sap_ha_pacemaker_cluster: ANGI on RHEL and small improvements (https://github.com/sap-linuxlab/community.sap_install/pull/911)
- sap_*_preconfigure, sap_ha_pacemaker_cluster: Reworked loading vars (https://github.com/sap-linuxlab/community.sap_install/pull/910)

Bugfixes
--------
- sap_swpm: Use master password only when necessary (https://github.com/sap-linuxlab/community.sap_install/pull/920)
- sap_swpm: Fix error when using tag sap_swpm_generate_inifile (https://github.com/sap-linuxlab/community.sap_install/pull/918)
- sap_swpm: Fix error when installing SAP NW750 JAVA or SOLMAN72SR2 JAVA instances (https://github.com/sap-linuxlab/community.sap_install/pull/916)
- sap_install_media_detect: Fix wrong sap_export_solman_java detection (https://github.com/sap-linuxlab/community.sap_install/pull/913)


v1.5.0
======

Expand Down
17 changes: 17 additions & 0 deletions changelogs/changelog.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -273,3 +273,20 @@ releases:
- sap_ha_install_anydb_ibmdb2: Linting and sles bug fixes (https://github.com/sap-linuxlab/community.sap_install/pull/803)
'
release_date: '2024-11-29'
1.5.1:
changes:
release_summary: '| Release Date: 2025-01-15
minor_changes:
- sap_ha_pacemaker_cluster: enable Simple Mount on RHEL (https://github.com/sap-linuxlab/community.sap_install/pull/931)
- sap_ha_pacemaker_cluster/SUSE: Rework SAPHanaSR-angi pre-steps and add SLES 16 vars (https://github.com/sap-linuxlab/community.sap_install/pull/928)
- sap_swpm, sap_general_preconfigure: Add variables for sap_install FQCN collection name for calling roles (https://github.com/sap-linuxlab/community.sap_install/pull/925)
- sap_general_preconfigure: Implement SAP note 2369910 (https://github.com/sap-linuxlab/community.sap_install/pull/914)
- sap_ha_pacemaker_cluster: ANGI on RHEL and small improvements (https://github.com/sap-linuxlab/community.sap_install/pull/911)
- sap_*_preconfigure, sap_ha_pacemaker_cluster: Reworked loading vars (https://github.com/sap-linuxlab/community.sap_install/pull/910)
bugfixes:
- sap_swpm: Use master password only when necessary (https://github.com/sap-linuxlab/community.sap_install/pull/920)
- sap_swpm: Fix error when using tag sap_swpm_generate_inifile (https://github.com/sap-linuxlab/community.sap_install/pull/918)
- sap_swpm: Fix error when installing SAP NW750 JAVA or SOLMAN72SR2 JAVA instances (https://github.com/sap-linuxlab/community.sap_install/pull/916)
- sap_install_media_detect: Fix wrong sap_export_solman_java detection (https://github.com/sap-linuxlab/community.sap_install/pull/913)
'
release_date: '2025-01-15'
2 changes: 1 addition & 1 deletion galaxy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace: community
name: sap_install

# The version of the collection. Must be compatible with semantic versioning
version: 1.5.0
version: 1.5.1

# The path to the Markdown (.md) readme file. This path is relative to the root of the collection
readme: README.md
Expand Down
6 changes: 6 additions & 0 deletions roles/sap_general_preconfigure/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ sap_general_preconfigure_system_roles_collection: 'fedora.linux_system_roles'
# - fedora.linux_system_roles
# - redhat.rhel_system_roles

sap_general_preconfigure_sap_install_collection: 'community.sap_install'
# Set which Ansible Collection to use when calling sap_install roles.

sap_general_preconfigure_enable_repos: false
# Set to `true` if you want the role to enable the repos as configured by the following repo related parameters.
# The default is `false`, meaning that the role will not enable repos.
Expand Down Expand Up @@ -166,4 +169,7 @@ sap_general_preconfigure_domain: "{{ sap_domain | d(ansible_domain) }}"
# Configuring Process Resource Limits
# Example: See README.md

# in SAP Note 2369910 SAP requires English locale
# If you want to define the locale set this to e.g. en_US.UTF-8
sap_general_preconfigure_default_locale: ""
# END: Default Variables for sap_general_preconfigure
14 changes: 14 additions & 0 deletions roles/sap_general_preconfigure/meta/argument_specs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,12 @@ argument_specs:
required: false
type: str

sap_general_preconfigure_sap_install_collection:
default: 'community.sap_install'
description: Set which Ansible Collection to use when calling sap_install roles.
required: false
type: str

sap_general_preconfigure_enable_repos:
default: false
description:
Expand Down Expand Up @@ -341,3 +347,11 @@ argument_specs:
sap_general_preconfigure_db_group_name: 'dba'
required: false
type: str

sap_general_preconfigure_default_locale:
description:
- Use this variable to specify the default system locale.
example:
sap_general_preconfigure_default_locale: 'en_US.UTF-8'
required: false
type: str
22 changes: 11 additions & 11 deletions roles/sap_general_preconfigure/tasks/RedHat/assert-installation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
- name: Assert - Get info about enabled repos
ansible.builtin.shell: set -o pipefail && subscription-manager repos --list-enabled | awk '/Repo ID:/{print $NF}'
register: __sap_general_preconfigure_register_enabled_repos_assert
changed_when: no
changed_when: false

- name: Assert that all required repos are enabled
ansible.builtin.assert:
Expand All @@ -69,8 +69,8 @@
- name: Detect if and how the minor RHEL release is set
ansible.builtin.shell: set -o pipefail && subscription-manager release | awk 'NF==2{printf $NF}NF!=2{print}'
register: __sap_general_preconfigure_register_subscription_manager_release_assert
changed_when: no
ignore_errors: yes
changed_when: false
ignore_errors: true

- name: Assert that the RHEL release is locked correctly
ansible.builtin.assert:
Expand Down Expand Up @@ -104,7 +104,7 @@
- name: Check if required RHEL 7 package groups are installed # noqa command-instead-of-shell
ansible.builtin.shell: "{{ __sap_general_preconfigure_fact_yum_group_list_installed_command_assert }}"
register: __sap_general_preconfigure_register_yum_group_assert
changed_when: no
changed_when: false

- name: Assert that all required RHEL 7 package groups are installed
ansible.builtin.assert:
Expand Down Expand Up @@ -133,7 +133,7 @@
- name: Check if required RHEL 8 environment groups are installed # noqa command-instead-of-shell
ansible.builtin.shell: "{{ __sap_general_preconfigure_fact_yum_envgroup_list_installed_command_assert }}"
register: __sap_general_preconfigure_register_yum_envgroup_assert
changed_when: no
changed_when: false

- name: Assert that all required RHEL 8 environment groups are installed
ansible.builtin.assert:
Expand Down Expand Up @@ -162,7 +162,7 @@
set -o pipefail && yum info installed {{ __sap_general_preconfigure_required_ppc64le | map('quote') | join(' ') }} |
awk '/Name/{n=$NF}/Version/{v=$NF}/Release/{r=$NF}/Description/{printf ("%s\n", n)}'
register: __sap_general_preconfigure_register_required_ppc64le_packages_assert
changed_when: no
changed_when: false
when: ansible_architecture == "ppc64le"
ignore_errors: "{{ sap_general_preconfigure_assert_ignore_errors | d(false) }}"

Expand Down Expand Up @@ -223,9 +223,9 @@
with_list: "{{ __sap_general_preconfigure_min_pkgs }}"
loop_control:
loop_var: pkg
check_mode: no
check_mode: false
register: __sap_general_preconfigure_register_minpkglist_assert
changed_when: no
changed_when: false

- name: Assert that minimum required package versions are installed
# If the output includes the string "is already installed" (case 2b), we have a PASS. Otherwise, it's a FAIL.
Expand All @@ -237,12 +237,12 @@
loop_control:
loop_var: line_item
label: ""
ignore_errors: yes
ignore_errors: true

- name: Report if no minimum required package version is defined for this RHEL release
ansible.builtin.debug:
msg: "INFO: No minimum required package version defined (variable __sap_general_preconfigure_min_pkgs)."
ignore_errors: yes
ignore_errors: true
when: not __sap_general_preconfigure_min_pkgs | d([])

# Reason for noqa: The yum module appears to not support the check-update option
Expand All @@ -265,7 +265,7 @@
- name: Report if checking for possible package updates is not requested
ansible.builtin.debug:
msg: "INFO: Not checking for possible package updates (variable sap_general_preconfigure_update)."
ignore_errors: yes
ignore_errors: true
when: not sap_general_preconfigure_update

- name: "Assert - Set needs-restarting command in case of RHEL 7"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
fail_msg: "FAIL: The DNS domain is not configured! So variable 'sap_general_preconfigure_domain' needs to be configured!"
success_msg: "PASS: The DNS domain is configured."
# ignore_errors: "{{ sap_general_preconfigure_assert_ignore_errors | d(false) }}"
ignore_errors: yes
ignore_errors: true

- name: Assert that variable sap_general_preconfigure_domain is set
ansible.builtin.assert:
Expand All @@ -25,8 +25,8 @@
- name: Check if IP address for sap_general_preconfigure_hostname.sap_general_preconfigure_domain is resolved correctly
ansible.builtin.command: dig {{ sap_general_preconfigure_hostname }}.{{ sap_general_preconfigure_domain }} +short
register: __sap_general_preconfigure_register_dig_short_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false
when: "'bind-utils' in ansible_facts.packages"

- name: Assert that ansible_default_ipv4.address is set
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
- name: Check if ipv4 address, FQDN, and hostname are once in /etc/hosts
ansible.builtin.command: awk 'BEGIN{a=0}/^{{ sap_general_preconfigure_ip }}\s/&&/\s{{ sap_general_preconfigure_hostname }}.{{ sap_general_preconfigure_domain }}\s/&&(/\s{{ sap_general_preconfigure_hostname }}\s/||/\s{{ sap_general_preconfigure_hostname }}$/){a++}END{print a}' /etc/hosts
register: __sap_general_preconfigure_register_ipv4_fqdn_sap_hostname_once_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false

- name: Assert that ipv4 address, FQDN, and hostname are once in /etc/hosts
ansible.builtin.assert:
Expand All @@ -25,8 +25,8 @@
- name: Count the number of sap_general_preconfigure_ip ({{ sap_general_preconfigure_ip }}) entries in /etc/hosts
ansible.builtin.command: awk 'BEGIN{a=0}/^{{ sap_general_preconfigure_ip }}\s/{a++}END{print a}' /etc/hosts
register: __sap_general_preconfigure_register_sap_ip_once_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false

- name: Assert that there is exactly one line containing {{ sap_general_preconfigure_ip }} in /etc/hosts
ansible.builtin.assert:
Expand All @@ -40,8 +40,8 @@
/\s{{ sap_general_preconfigure_hostname }}.{{ sap_general_preconfigure_domain }}\s/||
/\s{{ sap_general_preconfigure_hostname }}.{{ sap_general_preconfigure_domain }}$/{a++}END{print a}' /etc/hosts
register: __sap_general_preconfigure_register_fqdn_once_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false

- name: Assert that there is just one line containing {{ sap_general_preconfigure_hostname }}.{{ sap_general_preconfigure_domain }} in /etc/hosts
ansible.builtin.assert:
Expand All @@ -55,8 +55,8 @@
/\s{{ sap_general_preconfigure_hostname }}\s/||
/\s{{ sap_general_preconfigure_hostname }}$/{a++}END{print a}' /etc/hosts
register: __sap_general_preconfigure_register_sap_hostname_once_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false

- name: Assert that there is just one line containing {{ sap_general_preconfigure_hostname }} in /etc/hosts
ansible.builtin.assert:
Expand All @@ -68,8 +68,8 @@
- name: Test hostname -s
ansible.builtin.shell: test "$(hostname -s)" = "$(hostname)"
register: __sap_general_preconfigure_register_hostname_s_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false

- name: Assert that hostname -s matches the output of hostname
ansible.builtin.assert:
Expand All @@ -81,8 +81,8 @@
- name: Test hostname -f
ansible.builtin.shell: test "$(hostname -f)" = "$(hostname).$(hostname -d)"
register: __sap_general_preconfigure_register_hostname_f_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false

- name: Assert that hostname -f matches the output of hostname.hostname -d
ansible.builtin.assert:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
- name: Get status of firewalld # noqa command-instead-of-module
ansible.builtin.command: systemctl status firewalld
register: __sap_general_preconfigure_register_firewalld_status_assert
ignore_errors: yes
changed_when: no
no_log: yes
ignore_errors: true
changed_when: false
no_log: true

- name: Assert that firewalld is disabled
ansible.builtin.assert:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
- name: Check if hostname is set
ansible.builtin.command: hostname
register: __sap_general_preconfigure_register_hostname_assert
ignore_errors: yes
changed_when: no
ignore_errors: true
changed_when: false

- name: Assert that the output of hostname matches the content of variable sap_general_preconfigure_hostname
ansible.builtin.assert:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
- name: Get {{ line_item.name }} from {{ sap_general_preconfigure_etc_sysctl_sap_conf }}
ansible.builtin.shell: awk 'BEGIN{FS="="}/{{ line_item.name }}/{gsub ("^\\s*", "", $NF); print $NF}' {{ sap_general_preconfigure_etc_sysctl_sap_conf }}
register: __sap_general_preconfigure_register_sysctl_sap_conf_kernel_parameter_assert
changed_when: no
ignore_errors: yes
changed_when: false
ignore_errors: true
when: __sap_general_preconfigure_register_stat_sysctl_sap_conf_assert.stat.exists

- name: Assert that {{ line_item.name }} is set correctly in {{ sap_general_preconfigure_etc_sysctl_sap_conf }}
Expand All @@ -23,8 +23,8 @@
- name: Get {{ line_item.name }} from sysctl
ansible.builtin.shell: sysctl -n {{ line_item.name }} | awk '{gsub ("\t", " "); print}'
register: __sap_general_preconfigure_register_sysctl_kernel_parameter_assert
changed_when: no
ignore_errors: yes
changed_when: false
ignore_errors: true

- name: Assert that {{ line_item.name }} is set correctly as per sysctl
ansible.builtin.assert:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
- name: Check if the hard limit of nofile for group sapsys is 1048576
ansible.builtin.command: awk '!/^#/&&/sapsys/&&/nofile/&&/hard/{print $NF}' /etc/security/limits.d/99-sap.conf
register: __sap_general_preconfigure_register_limits_sap_conf_nofile_hard_assert
changed_when: no
ignore_errors: yes
changed_when: false
ignore_errors: true
when:
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.exists
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.isreg
Expand All @@ -25,8 +25,8 @@
- name: Check if the soft limit of nofile for group sapsys is 1048576
ansible.builtin.command: awk '!/^#/&&/sapsys/&&/nofile/&&/soft/{print $NF}' /etc/security/limits.d/99-sap.conf
register: __sap_general_preconfigure_register_limits_sap_conf_nofile_soft_assert
changed_when: no
ignore_errors: yes
changed_when: false
ignore_errors: true
when:
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.exists
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.isreg
Expand All @@ -46,8 +46,8 @@
- name: Get the hard limit of nofile for the database group
ansible.builtin.command: awk '!/^#/&&/@{{ sap_general_preconfigure_db_group_name }}/&&/nofile/&&/hard/{print $NF}' /etc/security/limits.d/99-sap.conf
register: __sap_general_preconfigure_register_limits_sap_conf_db_group_nofile_hard_assert
changed_when: no
ignore_errors: yes
changed_when: false
ignore_errors: true
when:
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.exists
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.isreg
Expand All @@ -67,8 +67,8 @@
- name: Get the soft limit of nofile for the database group
ansible.builtin.command: awk '!/^#/&&/@{{ sap_general_preconfigure_db_group_name }}/&&/nofile/&&/soft/{print $NF}' /etc/security/limits.d/99-sap.conf
register: __sap_general_preconfigure_register_limits_sap_conf_db_group_nofile_soft_assert
changed_when: no
ignore_errors: yes
changed_when: false
ignore_errors: true
when:
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.exists
- __sap_general_preconfigure_register_stat_limits_sap_conf_assert.stat.isreg
Expand Down
Loading

0 comments on commit a872878

Please sign in to comment.