From a580baf3765e7a8242ad3af2d4c3c42d29f09d0d Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 13:11:39 +0530 Subject: [PATCH 01/30] Update helpers.js --- src/js/helpers.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/js/helpers.js b/src/js/helpers.js index 35af872..8973432 100644 --- a/src/js/helpers.js +++ b/src/js/helpers.js @@ -891,6 +891,7 @@ if (typeof window !== 'undefined') { document.addEventListener('DOMContentLoaded', function onContentLoaded() { Helpers.update() document.removeEventListener('DOMContentLoaded', onContentLoaded) + console.log("Hello, world!"); }) } From 3b7deea66e0ce0a19228dfb4f1bec396c53f44cc Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 13:27:12 +0530 Subject: [PATCH 02/30] Create Jenkinsfile --- Jenkinsfile | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 Jenkinsfile diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..08df1d2 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,40 @@ +pipeline { + agent any + + environment { + BD_PROJECT_NAME = 'Samplepipeline' // Replace with your Black Duck project name + BD_VERSION_NAME = '1.0' // Replace with your version name + BD_SCAN_NAME = 'JenkinsScan' // Replace with a name for your scan + BD_API_TOKEN = credentials('NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==') // Jenkins credentials for Black Duck API token + BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL + SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name + } + + stages { + stage('Checkout') { + steps { + git branch: 'main', url: 'https://github.com/Hclishikawa/materio-bootstrap-html-aspnet-core-mvc-admin-template-free.git' + } + } + stage('Restore NuGet Packages') { + steps { + sh 'dotnet restore ${SOLUTION_NAME}' + } + } + + stage('Build') { + steps { + sh 'dotnet build ${SOLUTION_NAME} -c Release' + } + } + + stage('Black Duck Scan') { + steps { + withCredentials([string(credentialsId: 'black-duck-api-token', variable: 'BD_API_TOKEN')]) { + sh "detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" + } + } + } + } + +} From 860482f95447dc060dc5d29be9ff9d1282b85b10 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 13:32:37 +0530 Subject: [PATCH 03/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 08df1d2..28a3c93 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -5,7 +5,7 @@ pipeline { BD_PROJECT_NAME = 'Samplepipeline' // Replace with your Black Duck project name BD_VERSION_NAME = '1.0' // Replace with your version name BD_SCAN_NAME = 'JenkinsScan' // Replace with a name for your scan - BD_API_TOKEN = credentials('NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==') // Jenkins credentials for Black Duck API token + BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name } From ea386912bf7264958b73ceb9b5f03da72ed0c7d3 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 13:35:39 +0530 Subject: [PATCH 04/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 28a3c93..64d1bc0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -30,7 +30,7 @@ pipeline { stage('Black Duck Scan') { steps { - withCredentials([string(credentialsId: 'black-duck-api-token', variable: 'BD_API_TOKEN')]) { + withCredentials([string(variable: 'BD_API_TOKEN')]) { sh "detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" } } From ff39c37cc5f8e0534fb687105a91766ec070c5de Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 14:49:56 +0530 Subject: [PATCH 05/30] Update Jenkinsfile --- Jenkinsfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 64d1bc0..a3f4d56 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -29,8 +29,8 @@ pipeline { } stage('Black Duck Scan') { - steps { - withCredentials([string(variable: 'BD_API_TOKEN')]) { + steps { + withCredentials([string(credentialsId: 'black-duck-api-token', variable: 'BD_API_TOKEN')]) { sh "detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" } } From 7ea8dfb9e4100d7f2b7d6978fca6f8ad3d8d02d8 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 14:58:29 +0530 Subject: [PATCH 06/30] Update Jenkinsfile --- Jenkinsfile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index a3f4d56..9154be0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -29,12 +29,11 @@ pipeline { } stage('Black Duck Scan') { - steps { - withCredentials([string(credentialsId: 'black-duck-api-token', variable: 'BD_API_TOKEN')]) { - sh "detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" - } + steps { + sh "detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" } } + } } } From ef09a5c182ef63f8a096abb67e64652bd0de9164 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 14:59:52 +0530 Subject: [PATCH 07/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 9154be0..7c231f7 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -33,7 +33,7 @@ pipeline { sh "detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" } } - } + } } From 7894bfb15ba199e0010b0111b6add6ee9604f2ff Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 15:41:09 +0530 Subject: [PATCH 08/30] Update Jenkinsfile --- Jenkinsfile | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 7c231f7..b0620f0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,6 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name + DETECT_COMMAND = '/opt/Synopsys Detect' } stages { @@ -28,9 +29,21 @@ pipeline { } } - stage('Black Duck Scan') { + stage('Black Duck Scan') { steps { - sh "detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" + script { + sh """ + ${DETECT_COMMAND} --blackduck.url=\${BD_URL} \ + --blackduck.api.token=\${BD_API_TOKEN} \ + --blackduck.trust.cert=true \ + --detect.project.name=\${BD_PROJECT_NAME} \ + --detect.project.version.name=\${BD_VERSION_NAME} \ + --detect.code.location.name=\${BD_SCAN_NAME} \ + --detect.source.path=\${SOLUTION_NAME} \ + --detect.risk.report.pdf=true \ + --detect.risk.report.pdf.path=risk-report.pdf + """ + } } } From 73edd04cb0bca9e0ab1816e5a98d815d6e494762 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 15:43:15 +0530 Subject: [PATCH 09/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index b0620f0..80fdc1c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/opt/Synopsys Detect' + DETECT_COMMAND = '/opt/Synopsys Detect/synopsys-detect' } stages { From 3364726df20d8862781edadb7a72dfd0173d66f1 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:08:25 +0530 Subject: [PATCH 10/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 80fdc1c..22d500d 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/opt/Synopsys Detect/synopsys-detect' + DETECT_COMMAND = '/etc/alternatives/synopsys-detect' } stages { From 1ab35371df9f75273473075d37578d358433387b Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:13:58 +0530 Subject: [PATCH 11/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 22d500d..60ddf3c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/etc/alternatives/synopsys-detect' + DETECT_COMMAND = '/usr/local/bin/synopsys-detect' } stages { From 44d788e05cadd0d08a02bccf92761ae49b46ec72 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:16:30 +0530 Subject: [PATCH 12/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 60ddf3c..80fdc1c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/usr/local/bin/synopsys-detect' + DETECT_COMMAND = '/opt/Synopsys Detect/synopsys-detect' } stages { From ff94e8cb1c57b5c519a2bfe1e581f5130824c4e4 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:19:06 +0530 Subject: [PATCH 13/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 80fdc1c..22d500d 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/opt/Synopsys Detect/synopsys-detect' + DETECT_COMMAND = '/etc/alternatives/synopsys-detect' } stages { From e29a56f305d2e02851ed607c457ae377007b2fbd Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:27:30 +0530 Subject: [PATCH 14/30] Update Jenkinsfile --- Jenkinsfile | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 22d500d..943ad58 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -29,23 +29,24 @@ pipeline { } } - stage('Black Duck Scan') { - steps { - script { - sh """ - ${DETECT_COMMAND} --blackduck.url=\${BD_URL} \ - --blackduck.api.token=\${BD_API_TOKEN} \ - --blackduck.trust.cert=true \ - --detect.project.name=\${BD_PROJECT_NAME} \ - --detect.project.version.name=\${BD_VERSION_NAME} \ - --detect.code.location.name=\${BD_SCAN_NAME} \ - --detect.source.path=\${SOLUTION_NAME} \ - --detect.risk.report.pdf=true \ - --detect.risk.report.pdf.path=risk-report.pdf - """ - } - } + stage('Black Duck Scan') { + steps { + script { + sh """ + ${DETECT_COMMAND} --blackduck.url=${BD_URL} \ + --blackduck.api.token=${BD_API_TOKEN} \ + --blackduck.trust.cert=true \ + --detect.project.name=${BD_PROJECT_NAME} \ + --detect.project.version.name=${BD_VERSION_NAME} \ + --detect.code.location.name=${BD_SCAN_NAME} \ + --detect.source.path=${SOLUTION_NAME} \ + --detect.risk.report.pdf=true \ + --detect.risk.report.pdf.path=risk-report.pdf + """ } + } +} + } From 7a818de6afa146f0305b3ff5f941308da8ba5ef8 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:32:22 +0530 Subject: [PATCH 15/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 943ad58..f280607 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/etc/alternatives/synopsys-detect' + DETECT_COMMAND = '/opt/Synopsys Detect/synopsys-detect' } stages { From bca37cce19ea0cfc18e61397b822f1da9dcb2e38 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:38:10 +0530 Subject: [PATCH 16/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index f280607..a63ae65 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/opt/Synopsys Detect/synopsys-detect' + DETECT_COMMAND = '/opt/SynopsysDetect/synopsys-detect' } stages { From 6f83e213749196da3db7fd986d1d9fc0a814d108 Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:40:51 +0530 Subject: [PATCH 17/30] Update Jenkinsfile --- Jenkinsfile | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index a63ae65..0e0eb03 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -29,24 +29,13 @@ pipeline { } } - stage('Black Duck Scan') { - steps { - script { - sh """ - ${DETECT_COMMAND} --blackduck.url=${BD_URL} \ - --blackduck.api.token=${BD_API_TOKEN} \ - --blackduck.trust.cert=true \ - --detect.project.name=${BD_PROJECT_NAME} \ - --detect.project.version.name=${BD_VERSION_NAME} \ - --detect.code.location.name=${BD_SCAN_NAME} \ - --detect.source.path=${SOLUTION_NAME} \ - --detect.risk.report.pdf=true \ - --detect.risk.report.pdf.path=risk-report.pdf - """ + stage('Black Duck Scan') { + steps { + withEnv(['HEADLESS=true']) { + sh "/opt/SynopsysDetect/synopsys-detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" + } + } } - } -} - } From 7c26af37399bb45c99e32902bbfebd97d53e981d Mon Sep 17 00:00:00 2001 From: Hclishikawa <165147921+hclishikawa@users.noreply.github.com> Date: 2024年7月10日 16:59:59 +0530 Subject: [PATCH 18/30] Update Jenkinsfile --- Jenkinsfile | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 0e0eb03..db4ce6b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -5,10 +5,9 @@ pipeline { BD_PROJECT_NAME = 'Samplepipeline' // Replace with your Black Duck project name BD_VERSION_NAME = '1.0' // Replace with your version name BD_SCAN_NAME = 'JenkinsScan' // Replace with a name for your scan - BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Jenkins credentials for Black Duck API token + BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Replace with your actual token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name - DETECT_COMMAND = '/opt/SynopsysDetect/synopsys-detect' } stages { @@ -17,6 +16,7 @@ pipeline { git branch: 'main', url: 'https://github.com/Hclishikawa/materio-bootstrap-html-aspnet-core-mvc-admin-template-free.git' } } + stage('Restore NuGet Packages') { steps { sh 'dotnet restore ${SOLUTION_NAME}' @@ -29,14 +29,12 @@ pipeline { } } - stage('Black Duck Scan') { + stage('Black Duck Scan') { steps { withEnv(['HEADLESS=true']) { sh "/opt/SynopsysDetect/synopsys-detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" } } } - } - } From bb460e6462811ff49e0a0819e79d582f4921d26b Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 17:34:58 +0530 Subject: [PATCH 19/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index db4ce6b..dbd5d60 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -32,7 +32,7 @@ pipeline { stage('Black Duck Scan') { steps { withEnv(['HEADLESS=true']) { - sh "/opt/SynopsysDetect/synopsys-detect --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" + sh "java -jar /var/lib/jenkins/synopsys-detect/download/synopsys-detect-9.8.0.jar --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" } } } From 72a305fe48f7e568e1d0581c737791f1fc30ba2c Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 17:38:06 +0530 Subject: [PATCH 20/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index dbd5d60..73859c3 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,7 +13,7 @@ pipeline { stages { stage('Checkout') { steps { - git branch: 'main', url: 'https://github.com/Hclishikawa/materio-bootstrap-html-aspnet-core-mvc-admin-template-free.git' + git branch: 'main', url: 'https://github.com/Rohit45Marvel/materio-bootstrap-html-aspnet-core-mvc-admin-template-free.git' } } From 117df61f105281d3ffe3d57364a3416a010cb8c3 Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 18:27:47 +0530 Subject: [PATCH 21/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 73859c3..7e4073b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -32,7 +32,7 @@ pipeline { stage('Black Duck Scan') { steps { withEnv(['HEADLESS=true']) { - sh "java -jar /var/lib/jenkins/synopsys-detect/download/synopsys-detect-9.8.0.jar --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" + sh "java -jar /var/lib/jenkins/synopsys-detect/download/synopsys-detect-9.8.0.jar --blackduck.url=${BD_URL} --blackduck.api.token=${BD_API_TOKEN} --blackduck.trust.cert=true --detect.project.name=${BD_PROJECT_NAME} --detect.project.version.name=${BD_VERSION_NAME} --detect.code.location.name=${BD_SCAN_NAME} --detect.source.path=${SOLUTION_NAME} --blackduck.offline.mode=false --detect.risk.report.pdf=true --detect.risk.report.pdf.path=risk-report.pdf" } } } From dac2f1bcdea489f654b218a87d4cf48a5861dc64 Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:15:26 +0530 Subject: [PATCH 22/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 7e4073b..cf8d1ef 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -7,7 +7,7 @@ pipeline { BD_SCAN_NAME = 'JenkinsScan' // Replace with a name for your scan BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Replace with your actual token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL - SOLUTION_NAME = 'AspnetCoreMvcFull.sln' // Replace with your .NET solution file name + SOLUTION_NAME = '/var/lib/jenkins/workspace/NEwTEst/AspnetCoreMvcFull.sln' // Replace with your .NET solution file name } stages { From 84c22f3365d457fcc30b4b04b8b4e939d9ca9a54 Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:24:04 +0530 Subject: [PATCH 23/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index cf8d1ef..97c02ad 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -7,7 +7,7 @@ pipeline { BD_SCAN_NAME = 'JenkinsScan' // Replace with a name for your scan BD_API_TOKEN = 'NjI3YjYyY2ItZTIzOS00NTEwLWEyNjYtMTRjZjg2MTZlZTFkOjVhODc2ODMwLTRmYTctNDRmYS1iMGQ3LTI0NzI1MzVjYTY2Nw==' // Replace with your actual token BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL - SOLUTION_NAME = '/var/lib/jenkins/workspace/NEwTEst/AspnetCoreMvcFull.sln' // Replace with your .NET solution file name + SOLUTION_NAME = '/var/lib/jenkins/workspace/NEwTEst' // Replace with your .NET solution file name } stages { From 4816f5678d31b0cab06d6320e9b7a8df83494831 Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:32:03 +0530 Subject: [PATCH 24/30] Update Program.cs --- Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Program.cs b/Program.cs index 28e1687..a05a1d5 100644 --- a/Program.cs +++ b/Program.cs @@ -6,7 +6,7 @@ builder.Services.AddControllersWithViews(); var app = builder.Build(); - +console.WriteLine("Blackduck testing......."); // Configure the HTTP request pipeline. if (!app.Environment.IsDevelopment()) { From 969e09e7fd607f9b225b087c6497a6b1da167117 Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:34:10 +0530 Subject: [PATCH 25/30] Update Program.cs --- Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Program.cs b/Program.cs index a05a1d5..10bad4d 100644 --- a/Program.cs +++ b/Program.cs @@ -6,7 +6,7 @@ builder.Services.AddControllersWithViews(); var app = builder.Build(); -console.WriteLine("Blackduck testing......."); +console.WriteLine("Blackduck testing............."); // Configure the HTTP request pipeline. if (!app.Environment.IsDevelopment()) { From 80b604a222e943fabd64e547ddfb2909db5a14ac Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:43:03 +0530 Subject: [PATCH 26/30] Update Jenkinsfile --- Jenkinsfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Jenkinsfile b/Jenkinsfile index 97c02ad..4966505 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -9,6 +9,7 @@ pipeline { BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = '/var/lib/jenkins/workspace/NEwTEst' // Replace with your .NET solution file name } + triggers { githubPush() // This trigger listens for GitHub webhook events } stages { stage('Checkout') { From b1e99117d6f49a1829199ad9145dec1c055869a6 Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:43:54 +0530 Subject: [PATCH 27/30] Update Program.cs --- Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Program.cs b/Program.cs index 10bad4d..6e56903 100644 --- a/Program.cs +++ b/Program.cs @@ -6,7 +6,7 @@ builder.Services.AddControllersWithViews(); var app = builder.Build(); -console.WriteLine("Blackduck testing............."); +console.WriteLine("Blackduck testing................."); // Configure the HTTP request pipeline. if (!app.Environment.IsDevelopment()) { From f2839467f632cdcdf3bf89a677cdade7fd0f32d4 Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:44:59 +0530 Subject: [PATCH 28/30] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 4966505..658ae5b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -9,7 +9,7 @@ pipeline { BD_URL = 'https://poc416.blackduck.synopsys.com/' // Replace with your Black Duck server URL SOLUTION_NAME = '/var/lib/jenkins/workspace/NEwTEst' // Replace with your .NET solution file name } - triggers { githubPush() // This trigger listens for GitHub webhook events } + triggers { githubPush() } // This trigger listens for GitHub webhook events stages { stage('Checkout') { From 6bf960560930ec3d7926da57076a43dec4f2af7f Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:45:20 +0530 Subject: [PATCH 29/30] Update Program.cs --- Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Program.cs b/Program.cs index 6e56903..de8fb5e 100644 --- a/Program.cs +++ b/Program.cs @@ -6,7 +6,7 @@ builder.Services.AddControllersWithViews(); var app = builder.Build(); -console.WriteLine("Blackduck testing................."); +console.WriteLine("Blackduck testing.............."); // Configure the HTTP request pipeline. if (!app.Environment.IsDevelopment()) { From 0c18cf339d5d655d53c39c412419a5a82db84bcd Mon Sep 17 00:00:00 2001 From: Rohit45Marvel <165147921+rohit45marvel@users.noreply.github.com> Date: 2024年7月10日 19:47:26 +0530 Subject: [PATCH 30/30] Update Program.cs --- Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Program.cs b/Program.cs index de8fb5e..28e1687 100644 --- a/Program.cs +++ b/Program.cs @@ -6,7 +6,7 @@ builder.Services.AddControllersWithViews(); var app = builder.Build(); -console.WriteLine("Blackduck testing.............."); + // Configure the HTTP request pipeline. if (!app.Environment.IsDevelopment()) {