ansible-devops icon indicating copy to clipboard operation
ansible-devops copied to clipboard

is this variable MAS_APP_SETTINGS_DB2_SCHEMA only for DB2 or can be used for other supported DB servers

Open ekambaraml opened this issue 1 year ago • 3 comments

Manage install using Ansible playbook, The following env. variable is required.

export MAS_APP_SETTINGS_DB2_SCHEMA=maximo export MAS_APP_SETTINGS_TABLESPACE=maxdata export MAS_APP_SETTINGS_INDEXSPACE=maxindex

But the variable "MAS_APP_SETTINGS_DB2_SCHEMA" is misleading to assume, it is for DB2 only. Instead it can also be used with Oracle or MS SQL. Please confirm

ekambaraml avatar Jun 19 '24 15:06 ekambaraml

Example, customer Corning Inc. is using the Oracle Database on-perm.

ekambaraml avatar Jun 19 '24 15:06 ekambaraml

https://github.com/ibm-mas/ansible-devops/blob/master/docs/playbooks/oneclick-manage.md

ekambaraml avatar Jun 19 '24 15:06 ekambaraml

Looking into this for you now - will update when I have an answer

JonahLuckett avatar Jul 23 '24 12:07 JonahLuckett

Yes, this variable should be renamed as mas_app_settings_db_schema rather than db2_schema. The 2 looks like a mistake/autopilot when naming the variable.

@JonahLuckett When fixing this please ensure the old name is still supported ... e.g. docs etc can stop talking about db2_schema and only talk about db_schema, but have the code support both.

mas_app_settings_db2_schema: "{{ lookup('env', 'MAS_APP_SETTINGS_DB2_SCHEMA') | default('maximo', true)}}"
mas_app_settings_db_schema: "{{ lookup('env', 'MAS_APP_SETTINGS_DB_SCHEMA') | default(mas_app_settings_db2_schema, true)}}"

If my thinking is correct:

  • If neither are set then we default to maximo
  • If only mas_app_settings_db2_schema is set then we default mas_app_settings_db_schema to the value of mas_app_settings_db2_schema
  • If only mas_app_settings_db_schema is set then we use that
  • If both are set we use mas_app_settings_db_schema

So other than when we define the variables, we don't need to reference mas_app_settings_db2_schema anywhere in the docs or the code, but we can deliver this as a patch rather than a major as we are avoiding a breaking change

durera avatar Aug 23 '24 08:08 durera