From 72ed24b0532849d1d909062e64cb2bc7ad19b02c Mon Sep 17 00:00:00 2001 From: Ondra Machacek Date: Fri, 7 Oct 2022 10:42:09 +0200 Subject: [PATCH] Rename to sap.sap_operations Signed-off-by: Ondra Machacek --- README.md | 2 +- galaxy.yml | 2 +- plugins/modules/parameter_info.py | 8 ++++---- plugins/modules/rolling_kernel_switch.py | 4 ++-- plugins/modules/service.py | 12 ++++++------ plugins/modules/system.py | 8 ++++---- plugins/modules/system_info.py | 4 ++-- roles/sap_kernel_update/tasks/init.yml | 2 +- roles/sap_kernel_update/tasks/main.yml | 2 +- .../tasks/normal_kernel_upgrade.yml | 4 ++-- .../tasks/rolling_kernel_upgrade.yml | 2 +- 11 files changed, 25 insertions(+), 25 deletions(-) diff --git a/README.md b/README.md index bae3fab..f69e697 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ -# Ansible Collection - sap.operations +# Ansible Collection - sap.sap_operations This collection contains modules and plugins to assist in automating SAP day 2 operations with Ansible. diff --git a/galaxy.yml b/galaxy.yml index 4a325ac..eb0f4ab 100644 --- a/galaxy.yml +++ b/galaxy.yml @@ -5,7 +5,7 @@ namespace: sap # The name of the collection. Has the same character restrictions as 'namespace' -name: operations +name: sap_operations # The version of the collection. Must be compatible with semantic versioning version: 1.0.0 diff --git a/plugins/modules/parameter_info.py b/plugins/modules/parameter_info.py index 96242e1..ddc8721 100644 --- a/plugins/modules/parameter_info.py +++ b/plugins/modules/parameter_info.py @@ -61,18 +61,18 @@ EXAMPLES = r""" - name: Use module with local socket on target machine - sap.operations.parameter_info: + sap.sap_operations.parameter_info: instance_number: "0" - name: Fetch values of all parameters - sap.operations.parameter_info: + sap.sap_operations.parameter_info: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" instance_number: "0" - name: Fetch values of DIR_CT_RUN parameter - sap.operations.parameter_info: + sap.sap_operations.parameter_info: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" @@ -92,7 +92,7 @@ from ansible.module_utils.basic import AnsibleModule -from ansible_collections.sap.operations.plugins.module_utils import soap +from ansible_collections.sap.sap_operations.plugins.module_utils import soap def soap_client(hostname, username, password, ca_file, secure, instance): diff --git a/plugins/modules/rolling_kernel_switch.py b/plugins/modules/rolling_kernel_switch.py index ba22550..745fc0c 100644 --- a/plugins/modules/rolling_kernel_switch.py +++ b/plugins/modules/rolling_kernel_switch.py @@ -77,7 +77,7 @@ EXAMPLES = r""" - name: Run the system update - sap.operations.rolling_kernel_switch: + sap.sap_operations.rolling_kernel_switch: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" @@ -88,7 +88,7 @@ from ansible.module_utils.basic import AnsibleModule -from ansible_collections.sap.operations.plugins.module_utils import soap +from ansible_collections.sap.sap_operations.plugins.module_utils import soap def soap_client( diff --git a/plugins/modules/service.py b/plugins/modules/service.py index 1c00197..38c5a9c 100644 --- a/plugins/modules/service.py +++ b/plugins/modules/service.py @@ -76,17 +76,17 @@ EXAMPLES = r""" - name: Start the service and wait for service to be available using unix socket - sap.operations.service: + sap.sap_operations.service: instance_number: "0" - name: Start the service and wait for service to be available using username/password - sap.operations.service: + sap.sap_operations.service: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" - name: Start the service and do not wait for service to be up and running - sap.operations.service: + sap.sap_operations.service: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" @@ -95,14 +95,14 @@ wait: false - name: Stop the service and wait for termination - sap.operations.service: + sap.sap_operations.service: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" state: stopped - name: Stop the service and do not wait - sap.operations.service: + sap.sap_operations.service: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" @@ -128,7 +128,7 @@ from ansible.module_utils.basic import AnsibleModule -from ansible_collections.sap.operations.plugins.module_utils import soap +from ansible_collections.sap.sap_operations.plugins.module_utils import soap def soap_client( diff --git a/plugins/modules/system.py b/plugins/modules/system.py index 5d82825..35b6295 100644 --- a/plugins/modules/system.py +++ b/plugins/modules/system.py @@ -88,11 +88,11 @@ EXAMPLES = r""" - name: Use module with local socket on target machine - sap.operations.system: + sap.sap_operations.system: instance_number: "0" - name: Start system - sap.operations.system: + sap.sap_operations.system: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" @@ -100,7 +100,7 @@ state: started - name: Stop system - sap.operations.system: + sap.sap_operations.system: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" @@ -127,7 +127,7 @@ from ansible.module_utils.basic import AnsibleModule -from ansible_collections.sap.operations.plugins.module_utils import soap +from ansible_collections.sap.sap_operations.plugins.module_utils import soap def soap_client( diff --git a/plugins/modules/system_info.py b/plugins/modules/system_info.py index 9484e24..4ce0f3f 100644 --- a/plugins/modules/system_info.py +++ b/plugins/modules/system_info.py @@ -66,7 +66,7 @@ EXAMPLES = r""" - name: Fetch system info - sap.operations.system_info: + sap.sap_operations.system_info: username: "npladm" password: "secret123!" hostname: "sap.system.example.com" @@ -92,7 +92,7 @@ from ansible.module_utils.basic import AnsibleModule -from ansible_collections.sap.operations.plugins.module_utils import soap +from ansible_collections.sap.sap_operations.plugins.module_utils import soap def soap_client(hostname, username, password, ca_file, secure, instance): diff --git a/roles/sap_kernel_update/tasks/init.yml b/roles/sap_kernel_update/tasks/init.yml index ae74cb7..0e3728d 100644 --- a/roles/sap_kernel_update/tasks/init.yml +++ b/roles/sap_kernel_update/tasks/init.yml @@ -1,6 +1,6 @@ --- - name: Fetch kernel path - sap.operations.parameter_info: + sap.sap_operations.parameter_info: name: "DIR_CT_RUN" instance_number: "{{ sap_kernel_update_instance }}" register: __sap_kernel_update_sapexedb_sar_file diff --git a/roles/sap_kernel_update/tasks/main.yml b/roles/sap_kernel_update/tasks/main.yml index a53ae5e..307dba3 100644 --- a/roles/sap_kernel_update/tasks/main.yml +++ b/roles/sap_kernel_update/tasks/main.yml @@ -4,7 +4,7 @@ when: sap_kernel_update_kernel_path is not defined - name: Fetch the ABAP instances - sap.operations.system_info: + sap.sap_operations.system_info: instance_number: "{{ sap_kernel_update_instance }}" feature: "ABAP" register: __sap_kernel_update_apab_systems diff --git a/roles/sap_kernel_update/tasks/normal_kernel_upgrade.yml b/roles/sap_kernel_update/tasks/normal_kernel_upgrade.yml index 01a2eff..e06b9d9 100644 --- a/roles/sap_kernel_update/tasks/normal_kernel_upgrade.yml +++ b/roles/sap_kernel_update/tasks/normal_kernel_upgrade.yml @@ -1,5 +1,5 @@ - name: Stop SAP system - sap.operations.system: + sap.sap_operations.system: state: stopped instance_number: "{{ sap_kernel_update_instance }}" @@ -28,6 +28,6 @@ when: sap_kernel_updated_result is changed - name: Start SAP system - sap.operations.system: + sap.sap_operations.system: state: started instance_number: "{{ sap_kernel_update_instance }}" diff --git a/roles/sap_kernel_update/tasks/rolling_kernel_upgrade.yml b/roles/sap_kernel_update/tasks/rolling_kernel_upgrade.yml index f38f6a8..c4e9545 100644 --- a/roles/sap_kernel_update/tasks/rolling_kernel_upgrade.yml +++ b/roles/sap_kernel_update/tasks/rolling_kernel_upgrade.yml @@ -23,5 +23,5 @@ when: sap_kernel_updated_result is changed - name: Update SAP system - sap.operations.rolling_kernel_switch: + sap.sap_operations.rolling_kernel_switch: instance_number: "{{ sap_kernel_update_instance }}"