Skip to content

Commit

Permalink
Update method for calling WGet
Browse files Browse the repository at this point in the history
Signed-off-by: Brett Logan <[email protected]>
  • Loading branch information
lindluni committed Feb 13, 2024
1 parent ddc1ca6 commit af36741
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions jenkins/shared-libraries/linux/vars/ExecuteCodeQLWGet.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -230,21 +230,9 @@ def call(org, repo, branch, language, buildCommand, token, installCodeQL) {
echo "Uploading Database Bundle"
sizeInBytes=`stat --printf="%s" ${DATABASE_BUNDLE}`
if [ "${ENABLE_TLS_NO_VERIFY}" = true ]; then
wget --no-check-certificate --quiet --tries=3 --method=POST \
--header="Content-Type: application/zip" \
--header="Content-Length: $sizeInBytes" \
--header="${AUTHORIZATION_HEADER}" \
--body-file="${DATABASE_BUNDLE}" \
-O- \
"https://uploads.github.com/repos/$ORG/$REPO/code-scanning/codeql/databases/${LANGUAGE}?name=${DATABASE_BUNDLE}"
wget --no-check-certificate --quiet --tries=3 --method=POST --header="Content-Type: application/zip" --header="Content-Length: \$sizeInBytes" --header="${AUTHORIZATION_HEADER}" --body-file="${DATABASE_BUNDLE}" -O- "https://uploads.github.com/repos/$ORG/$REPO/code-scanning/codeql/databases/${LANGUAGE}?name=${DATABASE_BUNDLE}"
else
wget --quiet --tries=3 --method=POST \
--header="Content-Type: application/zip" \
--header="Content-Length: $sizeInBytes" \
--header="${AUTHORIZATION_HEADER}" \
--body-file="${DATABASE_BUNDLE}" \
-O- \
"https://uploads.github.com/repos/$ORG/$REPO/code-scanning/codeql/databases/${LANGUAGE}?name=${DATABASE_BUNDLE}"
wget --quiet --tries=3 --method=POST --header="Content-Type: application/zip" --header="Content-Length: \$sizeInBytes" --header="${AUTHORIZATION_HEADER}" --body-file="${DATABASE_BUNDLE}" -O- "https://uploads.github.com/repos/$ORG/$REPO/code-scanning/codeql/databases/${LANGUAGE}?name=${DATABASE_BUNDLE}"
fi
echo "Database Bundle uploaded"
fi
Expand Down

0 comments on commit af36741

Please sign in to comment.