Skip to content

Commit fce8a91

Browse files
committed
[ci] Build and deploy a binary for Linux musl x64
Fixes #111
1 parent 2f0e494 commit fce8a91

File tree

3 files changed

+15
-6
lines changed

3 files changed

+15
-6
lines changed

.github/workflows/ci.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,13 +61,17 @@ jobs:
6161
- uses: actions/checkout@v3
6262
- uses: actions/setup-node@v3
6363
with:
64-
node-version: 14
64+
node-version: 16
6565
architecture: ${{ matrix.arch }}
6666
- run: npm install
67-
- run: npm run prebuild
68-
if: matrix.os != 'macos-latest'
6967
- run: npm run prebuild-darwin-x64+arm64
7068
if: matrix.os == 'macos-latest'
69+
- run: |
70+
npm run prebuild
71+
npm run prebuild-linux-musl-x64
72+
if: matrix.os == 'ubuntu-18.04'
73+
- run: npm run prebuild
74+
if: matrix.os == 'windows-latest'
7175
- uses: actions/upload-artifact@v3
7276
with:
7377
name: ${{ matrix.os }}

binding.gyp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
{
2+
'variables': {
3+
'openssl_fips': ''
4+
},
25
'targets': [
36
{
47
'target_name': 'validation',

package.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@
88
},
99
"scripts": {
1010
"install": "node-gyp-build",
11-
"prebuild": "prebuildify --napi --strip --target=14.0.0",
12-
"prebuild-darwin-x64+arm64": "prebuildify --arch x64+arm64 --napi --strip --target=14.0.0",
11+
"prebuild": "prebuildify --napi --strip --target=8.11.2",
12+
"prebuild-linux-musl-x64": "prebuildify-cross --image alpine --napi --strip --target=8.11.2",
13+
"prebuild-darwin-x64+arm64": "prebuildify --arch x64+arm64 --napi --strip --target=8.11.2",
1314
"test": "mocha"
1415
},
1516
"files": [
@@ -41,6 +42,7 @@
4142
"devDependencies": {
4243
"mocha": "^10.0.0",
4344
"node-gyp": "^9.1.0",
44-
"prebuildify": "^5.0.0"
45+
"prebuildify": "^5.0.0",
46+
"prebuildify-cross": "^5.0.0"
4547
}
4648
}

0 commit comments

Comments
 (0)