mirror of
https://github.com/oxen-io/session-desktop.git
synced 2023-12-14 02:12:57 +01:00
Added mac signing
This commit is contained in:
parent
5e1e70ac8c
commit
103e5e0ab8
4 changed files with 46 additions and 9 deletions
9
build/entitlements.mac.plist
Normal file
9
build/entitlements.mac.plist
Normal file
|
@ -0,0 +1,9 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<!-- Mac distribution -->
|
||||
<key>com.apple.security.cs.allow-unsigned-executable-memory</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
|
@ -2,6 +2,7 @@
|
|||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<!-- Mac app store -->
|
||||
<key>com.apple.security.app-sandbox</key>
|
||||
<true/>
|
||||
<key>com.apple.security.network.client</key>
|
||||
|
|
28
build/notarize.js
Normal file
28
build/notarize.js
Normal file
|
@ -0,0 +1,28 @@
|
|||
const { notarize } = require("electron-notarize")
|
||||
|
||||
/*
|
||||
Pre-requisites: https://github.com/electron/electron-notarize#prerequisites
|
||||
1. Generate an app specific password
|
||||
2. Export SIGNING_APPLE_ID, SIGNING_APP_PASSWORD, SIGNING_TEAM_ID environment variables
|
||||
*/
|
||||
|
||||
/*
|
||||
Notarizing: https://kilianvalkhof.com/2019/electron/notarizing-your-electron-application/
|
||||
*/
|
||||
|
||||
exports.default = async function notarizing (context) {
|
||||
const { electronPlatformName, appOutDir } = context
|
||||
if (electronPlatformName !== "darwin") {
|
||||
return
|
||||
}
|
||||
|
||||
const appName = context.packager.appInfo.productFilename
|
||||
|
||||
return notarize({
|
||||
appBundleId: "com.loki-project.messenger-desktop",
|
||||
appPath: `${appOutDir}/${appName}.app`,
|
||||
appleId: process.env.SIGNING_APPLE_ID,
|
||||
appleIdPassword: process.env.SIGNING_APP_PASSWORD,
|
||||
ascProvider: process.env.SIGNING_TEAM_ID
|
||||
})
|
||||
}
|
17
package.json
17
package.json
|
@ -193,21 +193,20 @@
|
|||
"node": "10.13.0"
|
||||
},
|
||||
"build": {
|
||||
"appId": "org.loki.messenger-desktop",
|
||||
"appId": "com.loki-project.messenger-desktop",
|
||||
"afterSign": "build/notarize.js",
|
||||
"mac": {
|
||||
"artifactName": "${name}-mac-${version}.${ext}",
|
||||
"category": "public.app-category.social-networking",
|
||||
"icon": "build/icons/mac/icon.icns",
|
||||
"publish": [
|
||||
{
|
||||
"provider": "generic",
|
||||
"url": "https://updates.signal.org/desktop"
|
||||
}
|
||||
],
|
||||
"target": [
|
||||
"zip"
|
||||
"7z"
|
||||
],
|
||||
"bundleVersion": "1"
|
||||
"bundleVersion": "1",
|
||||
"hardenedRuntime": true,
|
||||
"gatekeeperAssess": false,
|
||||
"entitlements": "build/entitlements.mac.plist",
|
||||
"entitlementsInherit": "build/entitlements.mac.plist"
|
||||
},
|
||||
"win": {
|
||||
"asarUnpack": "node_modules/spellchecker/vendor/hunspell_dictionaries",
|
||||
|
|
Loading…
Reference in a new issue