Skip to content

Commit 5d944e6

Browse files
Fixes and documentation updates for Configuration Checks (#152)
1 parent 32daf5d commit 5d944e6

File tree

11 files changed

+46
-8
lines changed

11 files changed

+46
-8
lines changed

.github/workflows/ossf-scoreboard.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,6 @@ jobs:
5050
retention-days: 5
5151

5252
- name: "Upload to code-scanning"
53-
uses: github/codeql-action/upload-sarif@07bb2b932c90fc1ec97637495e4072a0966fa74c # v3.28.20
53+
uses: github/codeql-action/upload-sarif@32f7c15247fa6542dc765bd40f6a15dc2caeed89 # v4.31.2
5454
with:
5555
sarif_file: results.sarif

VERSION

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1.0.0

docs/CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
11
# Changelog
22

33
All notable changes to this project will be documented in this file.
4+
5+
6+
## 1.0.0
7+
Release Date: 11-04-2025
8+
9+
1. High Availability Functional Tests:
10+
- Added comprehensive functional tests for High Availability (HA) configurations for SAP HANA Database with scale-up architecture.
11+
- Added functional tests for HA configurations for SAP Central Services (ASCS) with Primary and Secondary nodes for ENSA1 and ENSA2 system types.
12+
- Support for running HA functional tests for systems with new HANA topology - SAP HANA SR-angi.
13+
- Offline Validation for HA configurations for SAP HANA Database and Central Services.
14+
2. Configuration Checks (preview release):
15+
- Initial implementation of configuration checks for SAP systems.
16+
- Support for validating SAP systems with HANA and IBM Db2 databases.

docs/CONFIGURATION_CHECKS.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,10 @@ You first need to make sure that you are logged into Azure CLI on the management
6868
az login --identity
6969

7070
# Login to Azure using User Assigned Managed Identity
71-
az login --identity -u <client-id-of-user-assigned-managed-identity>
71+
# When using management server with SLES or Ubuntu OS
72+
az login --identity -client-id <client-id-of-user-assigned-managed-identity>
73+
# When using management server with RHEL OS
74+
az login --identity --username <client-id-of-user-assigned-managed-identity>
7275

7376
# Set the desired subscription context
7477
az account set --subscription <subscription-id>

src/module_utils/filesystem_collector.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"""
55
Collectors for data collection in SAP Automation QA
66
"""
7+
import ipaddress
78
import json
89
import logging
910
from typing import Any

src/modules/render_html_report.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,11 @@
5353
- Reports will be created in {workspace_directory}/quality_assurance/
5454
type: str
5555
required: true
56+
framework_version:
57+
description:
58+
- Version of the SAP Automation QA framework
59+
type: str
60+
required: false
5661
author:
5762
- Microsoft Corporation
5863
notes:
@@ -71,6 +76,7 @@
7176
test_group_name: "hana_cluster_validation"
7277
report_template: "{{ lookup('file', 'templates/report_template.html') }}"
7378
workspace_directory: "/var/log/sap-automation-qa"
79+
framework_version: "1.0.0"
7480
register: report_result
7581
7682
- name: Show path to generated report
@@ -115,6 +121,7 @@ def __init__(
115121
workspace_directory: str,
116122
test_case_results: List[Dict[str, Any]] = [],
117123
system_info: Dict[str, Any] = {},
124+
framework_version: str = "unknown",
118125
):
119126
super().__init__()
120127
self.test_group_invocation_id = test_group_invocation_id
@@ -128,6 +135,7 @@ def __init__(
128135
)
129136
self.test_case_results = test_case_results or []
130137
self.system_info = system_info or {}
138+
self.framework_version = framework_version
131139

132140
def read_log_file(self) -> List[Dict[str, Any]]:
133141
"""
@@ -184,6 +192,7 @@ def render_report(self, test_case_results: List[Dict[str, Any]]) -> None:
184192
"%m/%d/%Y, %I:%M:%S %p"
185193
),
186194
"system_info": self.system_info,
195+
"framework_version": self.framework_version,
187196
}
188197
)
189198
)
@@ -205,6 +214,7 @@ def run_module() -> None:
205214
workspace_directory=dict(type="str", required=True),
206215
test_case_results=dict(type="list", required=False),
207216
system_info=dict(type="dict", required=False),
217+
framework_version=dict(type="str", required=False),
208218
)
209219

210220
module = AnsibleModule(argument_spec=module_args, supports_check_mode=True)
@@ -216,6 +226,7 @@ def run_module() -> None:
216226
workspace_directory=module.params["workspace_directory"],
217227
test_case_results=module.params.get("test_case_results", []),
218228
system_info=module.params.get("system_info", {}),
229+
framework_version=module.params.get("framework_version", "unknown"),
219230
)
220231

221232
test_case_results = (

src/roles/configuration_checks/tasks/files/hana.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1289,7 +1289,7 @@ checks:
12891289

12901290
- id: "DB-HANA-0050"
12911291
name: "Disk performance for /hana/data (MBPS)"
1292-
description: "The disk performance for /hana/data should be >= 64 MByte/s"
1292+
description: "The disk performance for /hana/data should be >= 400 MByte/s"
12931293
category: *sap_check
12941294
severity: *high
12951295
workload: *sap
@@ -1307,15 +1307,15 @@ checks:
13071307
mount_point: "/hana/data"
13081308
validator_type: *range
13091309
validator_args:
1310-
min: "64"
1310+
min: "400"
13111311
report: *check
13121312
references:
13131313
sap: "2972496"
13141314
microsoft: "https://docs.microsoft.com/en-us/azure/virtual-machines/workloads/sap/hana-vm-operations-storage"
13151315

13161316
- id: "DB-HANA-0051"
13171317
name: "Disk performance for /hana/log (MBPS)"
1318-
description: "The disk performance for /hana/log should be >= 64 MByte/s"
1318+
description: "The disk performance for /hana/log should be >= 250 MByte/s"
13191319
category: *sap_check
13201320
severity: *high
13211321
workload: *sap
@@ -1333,7 +1333,7 @@ checks:
13331333
mount_point: "/hana/log"
13341334
validator_type: *range
13351335
validator_args:
1336-
min: "64"
1336+
min: "250"
13371337
report: *check
13381338
references:
13391339
sap: "2972496"

src/roles/misc/tasks/render-html-report.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@
1414
ansible.builtin.set_fact:
1515
html_report_template: "{{ lookup('file', html_template_name | default('./templates/report.html')) }}"
1616

17+
- name: "Get framework version"
18+
no_log: true
19+
ansible.builtin.set_fact:
20+
framework_version: "{{ lookup('file', '../../../../VERSION') | default('unknown') }}"
21+
1722
- name: "Read the log file and create a HTML report"
1823
render_html_report:
1924
test_group_invocation_id: "{{ test_group_invocation_id }}"
@@ -22,4 +27,5 @@
2227
workspace_directory: "{{ _workspace_directory }}"
2328
test_case_results: "{{ all_results | default([]) }}"
2429
system_info: "{{ system_info | default({}) }}"
30+
framework_version: "{{ framework_version | default('unknown') }}"
2531
register: report_file_path

src/templates/config_checks_report.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1391,7 +1391,7 @@ <h4 class="section-header" onclick="toggleSection('section-{{ check.hostname }}-
13911391
</div>
13921392
</div>
13931393
</div>
1394-
<div class="footer">Report generated on: {{ report_generation_time }}</div>
1394+
<div class="footer">Report generated on: {{ report_generation_time }} with framework version: {{ framework_version }}</div>
13951395
<script>
13961396
function toggleDetails(checkId) {
13971397
const detailsRow = document.getElementById('details-' + checkId)

src/templates/report.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ <h2 class="system-info-heading">System Information</h2>
432432
</div>
433433
</div>
434434
</div>
435-
<div class="footer">Report generated on: {{ report_generation_time }}</div>
435+
<div class="footer">Report generated on: {{ report_generation_time }} with framework version: {{ framework_version }}</div>
436436
<script>
437437
// Function to beautify JSON objects
438438
function formatJsonObjects() {

0 commit comments

Comments
 (0)