chore: windows signing
This commit is contained in:
@@ -6,6 +6,10 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
Windows:
|
Windows:
|
||||||
runs-on: self-hosted
|
runs-on: self-hosted
|
||||||
|
env:
|
||||||
|
WINDOWS_TOKEN_ALIAS: ${{ secrets.WINDOWS_TOKEN_ALIAS }}
|
||||||
|
WINDOWS_TOKEN_PASSWORD: ${{ secrets.WINDOWS_TOKEN_PASSWORD }}
|
||||||
|
|
||||||
defaults:
|
defaults:
|
||||||
run:
|
run:
|
||||||
working-directory: packages/desktop
|
working-directory: packages/desktop
|
||||||
3
packages/desktop/jsign/eToken.cfg
Normal file
3
packages/desktop/jsign/eToken.cfg
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
name = HardwareToken
|
||||||
|
library = /Library/Frameworks/eToken.framework/Versions/A/libeToken.dylib
|
||||||
|
slotListIndex = 0
|
||||||
BIN
packages/desktop/jsign/jsign-4.1.jar
Normal file
BIN
packages/desktop/jsign/jsign-4.1.jar
Normal file
Binary file not shown.
@@ -113,7 +113,8 @@
|
|||||||
"win": {
|
"win": {
|
||||||
"certificateSubjectName": "Standard Notes Ltd.",
|
"certificateSubjectName": "Standard Notes Ltd.",
|
||||||
"publisherName": "Standard Notes Ltd.",
|
"publisherName": "Standard Notes Ltd.",
|
||||||
"signDlls": true
|
"signDlls": true,
|
||||||
|
"sign": "scripts/windowsSign.js"
|
||||||
},
|
},
|
||||||
"nsis": {
|
"nsis": {
|
||||||
"deleteAppDataOnUninstall": true
|
"deleteAppDataOnUninstall": true
|
||||||
|
|||||||
16
packages/desktop/scripts/windowsSign.js
Normal file
16
packages/desktop/scripts/windowsSign.js
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
exports.default = async function (configuration) {
|
||||||
|
require('child_process').execSync(
|
||||||
|
`java \
|
||||||
|
-jar jsign/jsign-4.1.jar \
|
||||||
|
--keystore jsign/eToken.cfg \
|
||||||
|
--storepass "${process.env.WINDOWS_TOKEN_PASSWORD}" \
|
||||||
|
--storetype PKCS11 \
|
||||||
|
--tsaurl http://timestamp.digicert.com \
|
||||||
|
--alias "${process.env.WINDOWS_TOKEN_ALIAS}" \
|
||||||
|
"${configuration.path}"
|
||||||
|
`,
|
||||||
|
{
|
||||||
|
stdio: 'inherit',
|
||||||
|
},
|
||||||
|
)
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user