SDA-2451: run snyk monitor on build scripts (#1109)

This commit is contained in:
Vishwas Shashidhar 2020-11-10 15:11:39 +05:30 committed by GitHub
parent 8ea3d6ae74
commit 3700c8b9ee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 12 additions and 4 deletions

View File

@ -2,6 +2,7 @@
NODE_REQUIRED_VERSION=v12.13.1
SNYK_ORG=sda
SNYK_PROJECT_NAME="Symphony Desktop Application"
if ! [ -x "$(command -v git)" ]; then
echo 'GIT does not exist! Please set it up before running this script!' >&2
@ -69,7 +70,8 @@ npm install
# Run Snyk Security Tests
echo "Running snyk security tests"
snyk test --file=package.json --org="$SNYK_ORG"
snyk test --file=package-lock.json --org="$SNYK_ORG"
snyk monitor --file=package-lock.json --org="$SNYK_ORG" --project-name="$SNYK_PROJECT_NAME"
# replace url in config
echo "Setting default pod url to https://corporate.symphony.com"

View File

@ -2,6 +2,7 @@
NODE_REQUIRED_VERSION=v12.13.1
SNYK_ORG=sda
SNYK_PROJECT_NAME="Symphony Desktop Application"
# Check basic dependencies
if ! [ -x "$(command -v git)" ]; then
@ -85,7 +86,8 @@ codesign --force --options runtime -s "Developer ID Application: Symphony Commun
# Run Snyk Security Tests
echo "Running snyk security tests"
snyk test --file=package.json --org="$SNYK_ORG"
snyk test --file=package-lock.json --org="$SNYK_ORG"
snyk monitor --file=package-lock.json --org="$SNYK_ORG" --project-name="$SNYK_PROJECT_NAME"
# Replace url in config
echo "Setting default pod url to https://my.symphony.com"

View File

@ -7,6 +7,7 @@ echo %PATH%
set DISABLE_REBUILD=true
set NODE_REQUIRED_VERSION=12.13.1
set SNYK_ORG=sda
set SNYK_PROJECT_NAME="Symphony Desktop Application"
set PATH=%PATH%;C:\Program Files\nodejs\;C:\Program Files\Git\cmd
echo %PATH%
@ -56,7 +57,8 @@ call npm install
# Run Snyk Security Tests
echo "Running snyk security tests"
call snyk test --file=package.json --org=%SNYK_ORG%
call snyk test --file=package-lock.json --org=%SNYK_ORG%
call snyk monitor --file=package-lock.json --org=%SNYK_ORG% --project-name=%SNYK_PROJECT_NAME%
:: Set expiry if required
IF "%EXPIRY_PERIOD%"=="" (

View File

@ -7,6 +7,7 @@ echo %PATH%
set DISABLE_REBUILD=true
set NODE_REQUIRED_VERSION=12.13.1
set SNYK_ORG=sda
set SNYK_PROJECT_NAME="Symphony Desktop Application"
set PATH=%PATH%;C:\Program Files\nodejs\;C:\Program Files\Git\cmd
echo %PATH%
@ -44,7 +45,8 @@ call npm install
# Run Snyk Security Tests
echo "Running snyk security tests"
call snyk test --file=package.json --org=%SNYK_ORG%
call snyk test --file=package-lock.json --org=%SNYK_ORG%
call snyk monitor --file=package-lock.json --org=%SNYK_ORG% --project-name=%SNYK_PROJECT_NAME%
:: Set expiry if required
IF "%EXPIRY_PERIOD%"=="" (