community.sap.sap_snote (1.0.0) — module

This module will upload and (de)implements C(SNOTES) in a SAP S4HANA environment.

| "added in version" 1.0.0 of community.sap"

Authors: Rainer Leber (@rainerleber)

Install collection

Install with ansible-galaxy collection install community.sap:==1.0.0


Add to requirements.yml

  collections:
    - name: community.sap
      version: 1.0.0

Description

The C(sap_snote) module depends on C(pyrfc) Python library (version 2.4.0 and upwards). Depending on distribution you are using, you may need to install additional packages to have these available.

This module will use the Function Group C(SCWB_API).

The C(TMS) must be configured at first.

Integrating SNOTES cannot be done via C(DDIC)- or C(SAP*)-User.


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: test snote module
  hosts: localhost
  tasks:
  - name: implement SNOTE
    community.sap.sap_snote:
      conn_username: 'DDIC'
      conn_password: 'Passwd1234'
      host: 192.168.1.100
      sysnr: '01'
      client: '000'
      state: present
      snote_path: /usr/sap/trans/tmp/0002949148.txt
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: test snote module without path
  hosts: localhost
  tasks:
  - name: deimplement SNOTE
    community.sap.sap_snote:
      conn_username: 'DDIC'
      conn_password: 'Passwd1234'
      host: 192.168.1.100
      sysnr: '01'
      client: '000'
      state: absent
      snote: 0002949148

Inputs

    
host:
    description: The required host for the SAP system. Can be either an FQDN or IP Address.
    required: true
    type: str

snote:
    description:
    - With the C(snote) paramter only implementation and deimplementation will work.
    - Upload SNOTES to the System is only available if C(snote_path) is provided.
    required: false
    type: str

state:
    choices:
    - present
    - absent
    default: present
    description:
    - The decision what to do with the SNOTE.
    - Could be C('present'), C('absent')
    required: false
    type: str

sysnr:
    default: '01'
    description:
    - The system number of the SAP system.
    - You must quote the value to ensure retaining the leading zeros.
    required: false
    type: str

client:
    default: '000'
    description:
    - The client number to connect to.
    - You must quote the value to ensure retaining the leading zeros.
    required: false
    type: str

snote_path:
    description:
    - The path to the extracted SNOTE txt file.
    - The File could be extracted from SAR package.
    - If C(snote_path) is not provided, the C(snote) parameter must be defined.
    - The SNOTE txt file must be at a place where the SAP System is authorized for. For
      example C(/usr/sap/trans/files).
    required: false
    type: str

conn_password:
    description: The required password for the SAP system.
    required: true
    type: str

conn_username:
    description: The required username for the SAP system.
    required: true
    type: str

Outputs

msg:
  description: A small execution description.
  returned: always
  sample: SNOTE 000298026 implemented.
  type: str
out:
  description: A complete description of the SNOTE implementation. If this is available.
  elements: dict
  returned: always
  sample: '{ "RETURN": [{"ES_MSG": { "MSGNO": "000", "MSGTY": "", "MSGTXT": "", "MSGV1":
    "" }, "ET_MSG": [], "EV_RC": 0, "ET_MISSING_NOTES": [], "IT_FILENAME": [{"FILENAME":
    "/usr/sap/trans/tmp/0002980265.txt"}], "IT_NOTES": [{"NUMM": "0002980265", "VERSNO":
    "0000"}] }]}'
  type: list