rhel-system-roles-sap/SOURCES/sap-hana-preconfigure-#116-...

62 lines
2.6 KiB
Diff

commit 752f988bf105a325db12965d240bbe1462b72c78
Author: Bernd Finger <bfinger@redhat.com>
Date: Tue Aug 4 17:12:44 2020 +0200
issue 116: add an option for not adding the repo for IBM service and productivity tools for POWER
diff --git a/README.md b/README.md
index eeb71dc..e921f16 100644
--- a/README.md
+++ b/README.md
@@ -112,6 +112,12 @@ If you want the role to set the RHEL release to a certain fixed minor release (a
sap_hana_preconfigure_set_minor_release
```
+### Add the repository for IBM service and productivity tools for POWER (ppc64le only)
+In case you do *not* want to automatically add the repository for the IBM service and productivity tools, set the following variable to `no`. Default is `yes`, meaning that the role will download and install the package specified in variable sap_hana_preconfigure_ibm_power_repo_url (see below) and also run the command /opt/ibm/lop/configure to accept the license.
+```yaml
+sap_hana_preconfigure_add_ibm_power_repo
+```
+
### URL for IBM service and productivity tools for POWER (ppc64le only)
The following variable is set to the location of package ibm-power-repo-lastest.noarch.rpm or a package with similar contents, as defined by variable __sap_hana_preconfigure_ibm_power_repo_url in vars/RedHat_7.yml and vars/RedHat_8.yml.
You can replace it by your own URL by setting this variable to a different URL.
diff --git a/defaults/main.yml b/defaults/main.yml
index 8d0d1d7..7a5d862 100644
--- a/defaults/main.yml
+++ b/defaults/main.yml
@@ -73,6 +73,8 @@ sap_hana_preconfigure_update: no
sap_hana_preconfigure_kernel_parameters: "{{ __sap_hana_preconfigure_kernel_parameters_default }}"
+sap_hana_preconfigure_add_ibm_power_repo: yes
+
# sap_hana_preconfigure_ibm_power_repo_url: 'http://public.dhe.ibm.com/software/server/POWER/Linux/yum/download/ibm-power-repo-3.0.0-19.noarch.rpm'
sap_hana_preconfigure_ibm_power_repo_url: "{{ __sap_hana_preconfigure_ibm_power_repo_url }}"
diff --git a/tasks/RedHat/installation.yml b/tasks/RedHat/installation.yml
index 9bd3dfa..7796420 100644
--- a/tasks/RedHat/installation.yml
+++ b/tasks/RedHat/installation.yml
@@ -64,14 +64,18 @@
yum:
name: "{{ sap_hana_preconfigure_ibm_power_repo_url }}"
state: present
- when: ansible_architecture == "ppc64le"
+ when:
+ - ansible_architecture == "ppc64le"
+ - sap_hana_preconfigure_add_ibm_power_repo|d(true)
- name: Accept the license for the IBM tools
shell: |
MORE=+1000 /opt/ibm/lop/configure <<-EOF
y
EOF
- when: ansible_architecture == "ppc64le"
+ when:
+ - ansible_architecture == "ppc64le"
+ - sap_hana_preconfigure_add_ibm_power_repo|d(true)
- name: Install IBM tools
package: