Skip to content

Commit

Permalink
Merge pull request #1333 from snyk/chore/node-12
Browse files Browse the repository at this point in the history
Remove npmignore and downgrade binary NodeJS version 14->12
  • Loading branch information
JackuB committed Aug 14, 2020
2 parents c49d942 + 957c64e commit 17552b6
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 18 deletions.
10 changes: 0 additions & 10 deletions .npmignore

This file was deleted.

9 changes: 7 additions & 2 deletions .releaserc
Expand Up @@ -9,7 +9,7 @@
{
"//": "build the alpine, macos, linux and windows binaries",
"path": "@semantic-release/exec",
"cmd": "pkg . -t node14-alpine-x64,node14-linux-x64,node14-macos-x64,node14-win-x64"
"cmd": "pkg . -t node12-alpine-x64,node12-linux-x64,node12-macos-x64,node12-win-x64"
},
{
"//": "build docker package",
Expand Down Expand Up @@ -78,9 +78,14 @@
"label": "snyk-alpine.sha256"
},
{
"path": "./dist/docker-mac-signed-bundle.tar.gz",
"path": "./docker-mac-signed-bundle.tar.gz",
"name": "docker-mac-signed-bundle.tar.gz",
"label": "docker-mac-signed-bundle.tar.gz"
},
{
"path": "./docker-mac-signed-bundle.tar.gz.sha256",
"name": "docker-mac-signed-bundle.tar.gz.sha256",
"label": "docker-mac-signed-bundle.tar.gz.sha256"
}
]
}
Expand Down
5 changes: 2 additions & 3 deletions package.json
Expand Up @@ -7,9 +7,8 @@
"dist",
"config.default.json",
"SECURITY.md",
"README.md",
"Contributor-Agreement.md",
".snyk"
"LICENSE",
"README.md"
],
"directories": {
"test": "test"
Expand Down
8 changes: 6 additions & 2 deletions release-scripts/docker-desktop-release.sh
Expand Up @@ -16,15 +16,19 @@ cp ./release-scripts/snyk-mac.sh ./dist/docker/
cd ./dist/docker

npm install --production
rm -rf package-lock.json

# Download macOS NodeJS binary, using same as pkg
curl "https://nodejs.org/dist/v14.6.0/node-v14.6.0-darwin-x64.tar.gz" | tar -xz
curl "https://nodejs.org/dist/v12.18.3/node-v12.18.3-darwin-x64.tar.gz" | tar -xz

cd ..

# Create bundle, resolve symlinks
tar czfh docker-mac-signed-bundle.tar.gz ./docker
# final package must be at root, otherwise it gets included in /dist folder
cd ..
mv ./dist/docker-mac-signed-bundle.tar.gz .

sha256sum docker-mac-signed-bundle.tar.gz > docker-mac-signed-bundle.tar.gz.sha256

rm -rf ./docker
rm -rf ./dist/docker
2 changes: 1 addition & 1 deletion release-scripts/snyk-mac.sh
Expand Up @@ -3,7 +3,7 @@ set -e

DIRNAME=$(dirname "$0")

NODE="$DIRNAME/node-v14.6.0-darwin-x64/bin/node"
NODE="$DIRNAME/node-v12.18.3-darwin-x64/bin/node"
SNYK_CLI="$DIRNAME/cli/cli/index.js"

"$NODE" "$SNYK_CLI" "$@"

0 comments on commit 17552b6

Please sign in to comment.