SERVER-110489: use github_commit expansion and cd into 10gen/mongo to get commit datetime for SAST report generation (#41108)
GitOrigin-RevId: c4c66f27ecf7d99c88947b5de0642cdc2db6af58
This commit is contained in:
parent
91f7205349
commit
d3f99007aa
@ -33,6 +33,7 @@ tasks:
|
||||
env:
|
||||
WORK_DIR: ${workdir}
|
||||
MODULE_PATH: ${workdir}/devprodCoveritySrc/devprod_coverity
|
||||
GITHUB_COMMIT: ${github_commit}
|
||||
TRIGGERED_BY_GIT_TAG: ${triggered_by_git_tag}
|
||||
MONGODB_VERSION: ${version}
|
||||
MONGODB_RELEASE_BRANCH: ${branch_name}
|
||||
|
||||
@ -36,3 +36,9 @@ filters:
|
||||
- "perf-submission.sh":
|
||||
approvers:
|
||||
- 10gen/devprod-performance-analysis
|
||||
- "generate_sast_report.sh":
|
||||
approvers:
|
||||
- 10gen/devprod-release-infrastructure
|
||||
- "write_sast_report_env_file.sh":
|
||||
approvers:
|
||||
- 10gen/devprod-release-infrastructure
|
||||
|
||||
@ -1,10 +1,14 @@
|
||||
#!/bin/env bash
|
||||
set -eux
|
||||
|
||||
# get the datetime for the current commit SHA
|
||||
cd ${WORK_DIR}/src
|
||||
commit_datetime=$(git show -s --format=%cd --date=iso-strict ${GITHUB_COMMIT})
|
||||
echo "Date and time of commit: $commit_datetime"
|
||||
|
||||
# generate the SAST report
|
||||
cd ${MODULE_PATH}/scripts
|
||||
echo "Running SAST report generation script..."
|
||||
commit_datetime=$(git log -1 --format=%cd --date=iso-strict)
|
||||
echo "Date and time of commit: $commit_datetime"
|
||||
virtualenv -p python3.12 .venv
|
||||
source .venv/bin/activate
|
||||
pip install -r sast_reporting/requirements.txt
|
||||
|
||||
Loading…
Reference in New Issue
Block a user