Skip to content

Commit 60eff4d

Browse files
committed
vfs fixes
Signed-off-by: Manimaran-MM <manim@redhat.com>
1 parent 6f6b57c commit 60eff4d

File tree

3 files changed

+475
-473
lines changed

3 files changed

+475
-473
lines changed

ci_utils/vfs/vfs_setup.py

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ def configure_export(self):
4747
Path = "/{self.vfs_volume}";
4848
Pseudo = "/{self.vfs_volume}";
4949
Access_type = RW;
50-
Disable_ACL = True;
50+
Disable_ACL = False;
5151
Protocols = "3","4";
5252
Transports = "UDP","TCP";
5353
SecType = "sys";
@@ -83,18 +83,18 @@ def validate_export(self):
8383
# -------------------------------
8484
def enable_acl_if_required(self):
8585
logger.info("[TEST]: Checking if ACL needs to be enabled")
86-
if self.enable_acl:
87-
logger.info("Enabling ACL for volume...")
88-
run_cmd(self.session, f"sed -i s/'Disable_ACL = .*'/'Disable_ACL = false;'/g {self.export_conf}")
89-
run_cmd(self.session, f"cat {self.export_conf}")
90-
export_id, _ = run_cmd(self.session, f"grep 'Export_Id' {self.export_conf} | sed 's/^[[:space:]]*Export_Id.*=[[:space:]]*\\([0-9]*\\).*/\\1/'")
91-
run_cmd(
92-
self.session,
93-
f"dbus-send --type=method_call --print-reply --system "
94-
f"--dest=org.ganesha.nfsd /org/ganesha/nfsd/ExportMgr "
95-
f"org.ganesha.nfsd.exportmgr.UpdateExport string:{self.export_conf} "
96-
f"string:\"EXPORT(Export_Id = {export_id})\""
97-
)
86+
# if self.enable_acl:
87+
# # logger.info("Enabling ACL for volume...")
88+
# # run_cmd(self.session, f"sed -i s/'Disable_ACL = .*'/'Disable_ACL = false;'/g {self.export_conf}")
89+
# run_cmd(self.session, f"cat {self.export_conf}")
90+
# export_id, _ = run_cmd(self.session, f"grep 'Export_Id' {self.export_conf} | sed 's/^[[:space:]]*Export_Id.*=[[:space:]]*\\([0-9]*\\).*/\\1/'")
91+
# run_cmd(
92+
# self.session,
93+
# f"dbus-send --type=method_call --print-reply --system "
94+
# f"--dest=org.ganesha.nfsd /org/ganesha/nfsd/ExportMgr "
95+
# f"org.ganesha.nfsd.exportmgr.UpdateExport string:{self.export_conf} "
96+
# f"string:\"EXPORT(Export_Id = {export_id})\""
97+
# )
9898

9999
# -------------------------------
100100
# Enable Security_Label if required

jobs/Jenkinsfile.gatecheck

Lines changed: 105 additions & 105 deletions
Original file line numberDiff line numberDiff line change
@@ -165,116 +165,116 @@ pipeline {
165165
}
166166
}
167167

168-
stage('Pre-Check Patchset - Initial') {
169-
steps {
170-
script {
171-
preCheckGerritPatchset()
172-
}
173-
}
174-
}
175-
176-
stage('Run Checkpatch, Clang and FSAL Tests') {
177-
steps {
178-
sh """
179-
export GIT_CLONE_DEPTH=2
180-
export NODE_COUNT=1
181-
182-
echo "[PIPELINE]: Reserving nodes for tests..."
183-
pytest -v -s ci-tests/tests/test_reserve_nodes.py
184-
185-
echo "[PIPELINE]: Setting up common test environment..."
186-
pytest -c ci-tests/ci_utils/pytest.ini -v -s -m checkpatch_fsal ci-tests/tests/test_ci_pre_req.py
187-
188-
echo "[PIPELINE]: Running tests..."
189-
pytest -v -n 6 --capture=no --junitxml=report-checkpatch-fsal.xml ci-tests/tests/test_checkpatch_fsal.py
190-
"""
191-
}
168+
// stage('Pre-Check Patchset - Initial') {
169+
// steps {
170+
// script {
171+
// preCheckGerritPatchset()
172+
// }
173+
// }
174+
// }
175+
176+
// stage('Run Checkpatch, Clang and FSAL Tests') {
177+
// steps {
178+
// sh """
179+
// export GIT_CLONE_DEPTH=2
180+
// export NODE_COUNT=1
181+
182+
// echo "[PIPELINE]: Reserving nodes for tests..."
183+
// pytest -v -s ci-tests/tests/test_reserve_nodes.py
184+
185+
// echo "[PIPELINE]: Setting up common test environment..."
186+
// pytest -c ci-tests/ci_utils/pytest.ini -v -s -m checkpatch_fsal ci-tests/tests/test_ci_pre_req.py
187+
188+
// echo "[PIPELINE]: Running tests..."
189+
// pytest -v -n 6 --capture=no --junitxml=report-checkpatch-fsal.xml ci-tests/tests/test_checkpatch_fsal.py
190+
// """
191+
// }
192192

193-
post {
194-
always {
195-
echo "Deleting reserved nodes..."
196-
sh 'pytest -v -s ci-tests/tests/test_delete_nodes.py'
193+
// post {
194+
// always {
195+
// echo "Deleting reserved nodes..."
196+
// sh 'pytest -v -s ci-tests/tests/test_delete_nodes.py'
197197

198-
script {
199-
def filesToCat = [
200-
"${WORKSPACE}/failures/checkpatch_logs.json",
201-
"${WORKSPACE}/failures/clang_logs.json",
202-
"${WORKSPACE}/summary_checkpatch_fsal.txt",
203-
"${WORKSPACE}/summary_status.txt"
204-
]
205-
206-
filesToCat.each { file ->
207-
if (fileExists(file)) {
208-
sh "cat ${file}"
209-
}
210-
}
211-
212-
213-
def notifyFlag = '--notify NONE'
214-
def verifiedFlag = ''
215-
def postCheckpatchFailure = false
216-
def postClangFailure = false
217-
def statusFile = "${WORKSPACE}/summary_status.txt"
218-
def checkpatchJSONFile = "${WORKSPACE}/failures/checkpatch_logs.json"
219-
def clangJSONFile = "${WORKSPACE}/failures/clang_logs.json"
220-
221-
if (fileExists(statusFile)) {
222-
def content = readFile(statusFile).trim()
223-
echo "Summary status: ${content}"
224-
225-
if (content.contains('Failed')) {
226-
notifyFlag = '--notify ALL'
227-
echo "Test failed → setting notifyFlag=${notifyFlag}"
228-
}
229-
} else {
230-
echo "summary_status.txt not found, using default flags"
231-
}
232-
233-
// Check for Clang-format & Checkpatch failures in the JSON file to post to gerrit as inline comments
234-
if (fileExists(checkpatchJSONFile)) {
235-
def checkpatch_content = readFile(checkpatchJSONFile).trim()
236-
echo "Checkpatch JSON content: ${checkpatch_content}"
198+
// script {
199+
// def filesToCat = [
200+
// "${WORKSPACE}/failures/checkpatch_logs.json",
201+
// "${WORKSPACE}/failures/clang_logs.json",
202+
// "${WORKSPACE}/summary_checkpatch_fsal.txt",
203+
// "${WORKSPACE}/summary_status.txt"
204+
// ]
205+
206+
// filesToCat.each { file ->
207+
// if (fileExists(file)) {
208+
// sh "cat ${file}"
209+
// }
210+
// }
211+
212+
213+
// def notifyFlag = '--notify NONE'
214+
// def verifiedFlag = ''
215+
// def postCheckpatchFailure = false
216+
// def postClangFailure = false
217+
// def statusFile = "${WORKSPACE}/summary_status.txt"
218+
// def checkpatchJSONFile = "${WORKSPACE}/failures/checkpatch_logs.json"
219+
// def clangJSONFile = "${WORKSPACE}/failures/clang_logs.json"
220+
221+
// if (fileExists(statusFile)) {
222+
// def content = readFile(statusFile).trim()
223+
// echo "Summary status: ${content}"
224+
225+
// if (content.contains('Failed')) {
226+
// notifyFlag = '--notify ALL'
227+
// echo "Test failed → setting notifyFlag=${notifyFlag}"
228+
// }
229+
// } else {
230+
// echo "summary_status.txt not found, using default flags"
231+
// }
232+
233+
// // Check for Clang-format & Checkpatch failures in the JSON file to post to gerrit as inline comments
234+
// if (fileExists(checkpatchJSONFile)) {
235+
// def checkpatch_content = readFile(checkpatchJSONFile).trim()
236+
// echo "Checkpatch JSON content: ${checkpatch_content}"
237237

238-
if (!checkpatch_content.contains("Checkpatch OK")) {
239-
postCheckpatchFailure = true
240-
echo "Checkpatch failure detected → setting postCheckpatchFailure=${postCheckpatchFailure}"
241-
}
242-
}
238+
// if (!checkpatch_content.contains("Checkpatch OK")) {
239+
// postCheckpatchFailure = true
240+
// echo "Checkpatch failure detected → setting postCheckpatchFailure=${postCheckpatchFailure}"
241+
// }
242+
// }
243243

244-
if (fileExists(clangJSONFile)) {
245-
def clang_content = readFile(clangJSONFile).trim()
246-
echo "Clang JSON content: ${clang_content}"
244+
// if (fileExists(clangJSONFile)) {
245+
// def clang_content = readFile(clangJSONFile).trim()
246+
// echo "Clang JSON content: ${clang_content}"
247247

248-
if (!clang_content.contains("clang-format OK")) {
249-
postClangFailure = true
250-
echo "Clang-format failure detected → setting postClangFailure=${postClangFailure}"
251-
}
252-
}
253-
254-
postToGerrit("${WORKSPACE}/summary_checkpatch_fsal.txt", notifyFlag, verifiedFlag, postCheckpatchFailure, "${WORKSPACE}/failures/checkpatch_logs.json", postClangFailure, "${WORKSPACE}/failures/clang_logs.json")
255-
256-
def failuresFolder = "${WORKSPACE}/failures"
257-
def failuresFiles = findFiles(glob: 'failures/**')
258-
259-
if (fileExists("${WORKSPACE}/failures")) {
260-
archiveArtifacts artifacts: 'failures/**', allowEmptyArchive: true
261-
} else {
262-
echo "No failures folder found, skipping artifact archive."
263-
}
264-
}
265-
// Publish test results
266-
junit 'report-checkpatch-fsal.xml'
267-
}
268-
}
269-
}
270-
271-
stage('Pre-Check Patchset - Intermediate') {
272-
steps {
273-
script {
274-
preCheckGerritPatchset()
275-
}
276-
}
277-
}
248+
// if (!clang_content.contains("clang-format OK")) {
249+
// postClangFailure = true
250+
// echo "Clang-format failure detected → setting postClangFailure=${postClangFailure}"
251+
// }
252+
// }
253+
254+
// postToGerrit("${WORKSPACE}/summary_checkpatch_fsal.txt", notifyFlag, verifiedFlag, postCheckpatchFailure, "${WORKSPACE}/failures/checkpatch_logs.json", postClangFailure, "${WORKSPACE}/failures/clang_logs.json")
255+
256+
// def failuresFolder = "${WORKSPACE}/failures"
257+
// def failuresFiles = findFiles(glob: 'failures/**')
258+
259+
// if (fileExists("${WORKSPACE}/failures")) {
260+
// archiveArtifacts artifacts: 'failures/**', allowEmptyArchive: true
261+
// } else {
262+
// echo "No failures folder found, skipping artifact archive."
263+
// }
264+
// }
265+
// // Publish test results
266+
// junit 'report-checkpatch-fsal.xml'
267+
// }
268+
// }
269+
// }
270+
271+
// stage('Pre-Check Patchset - Intermediate') {
272+
// steps {
273+
// script {
274+
// preCheckGerritPatchset()
275+
// }
276+
// }
277+
// }
278278

279279
stage('Run Pynfs and Cthon Tests') {
280280
steps {

0 commit comments

Comments
 (0)