2019-09-25 23:28:15 +02:00
|
|
|
name: Build macOS Client
|
|
|
|
|
|
|
|
on: [push, pull_request]
|
|
|
|
|
|
|
|
jobs:
|
2019-10-05 21:15:34 +02:00
|
|
|
build_darwin:
|
2019-09-25 23:28:15 +02:00
|
|
|
runs-on: macos-latest
|
|
|
|
steps:
|
|
|
|
- name: Clone source code
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
- name: Use Node.js
|
|
|
|
uses: actions/setup-node@v1
|
|
|
|
with:
|
|
|
|
node-version: 10.x
|
2019-12-18 20:11:10 +01:00
|
|
|
- name: Install certificates and entitlements
|
2019-12-18 20:09:05 +01:00
|
|
|
if: github.actor == 'alicerunsonfedora' || github.actor == 'Nomad1556' || github.actor == 'audmaxwell'
|
2019-09-26 00:01:40 +02:00
|
|
|
run: |
|
2019-09-26 15:46:28 +02:00
|
|
|
echo "Downloading certificates and profiles..."
|
2019-09-26 00:08:05 +02:00
|
|
|
echo "$ascCertificates" > certs.b64
|
2019-09-26 15:46:28 +02:00
|
|
|
echo "$ascMasProfile" > mas.b64
|
|
|
|
echo "$ascMacProfile" > mac.b64
|
|
|
|
echo "$ascEntitlementsMas" > entmas.b64
|
|
|
|
echo "$ascEntitlementsMac" > entmac.b64
|
|
|
|
echo "$ascInfoPlist" > info.b64
|
|
|
|
|
|
|
|
echo "Installing certificates and profiles..."
|
2019-09-26 00:05:45 +02:00
|
|
|
base64 --decode certs.b64 > Certificates.p12
|
2019-09-26 15:47:51 +02:00
|
|
|
base64 --decode mas.b64 > desktop/embedded.provisionprofile
|
2019-09-26 15:46:28 +02:00
|
|
|
base64 --decode mac.b64 > desktop/nonmas.provisionprofile
|
|
|
|
base64 --decode entmas.b64 > desktop/entitlements.mas.plist
|
|
|
|
base64 --decode entmac.b64 > desktop/entitlements.mac.plist
|
|
|
|
base64 --decode info.b64 > desktop/info.plist
|
2019-09-26 00:08:05 +02:00
|
|
|
security add-generic-password -a "appleseed@marquiskurt.net" -w "$ascPassword" -s "AC_PASSWORD"
|
2019-09-26 00:09:30 +02:00
|
|
|
sudo security import Certificates.p12 -P "$ascCertsPassword" -k /Library/Keychains/System.keychain
|
2019-09-26 00:03:08 +02:00
|
|
|
env:
|
2019-09-26 00:01:40 +02:00
|
|
|
ascPassword: ${{ secrets.ASC_PASSWORD }}
|
|
|
|
ascCertificates: ${{ secrets.ASC_CERTS }}
|
|
|
|
ascCertsPassword: ${{ secrets.ASC_CERTS_PASSWORD }}
|
2019-09-26 15:46:28 +02:00
|
|
|
ascMacProfile: ${{ secrets.ASC_NONMAS_PROFILE }}
|
|
|
|
ascMasProfile: ${{ secrets.ASC_EMBEDDED_PROFILE }}
|
|
|
|
ascEntitlementsMas: ${{ secrets.ASC_MAS_ENTITLEMENTS }}
|
|
|
|
ascEntitlementsMac: ${{ secrets.ASC_MAC_ENTITLEMENTS }}
|
|
|
|
ascInfoPlist: ${{ secrets.ASC_INFO_PLIST }}
|
2019-09-25 23:28:15 +02:00
|
|
|
- name: Install dependencies and build
|
|
|
|
run: |
|
|
|
|
npm install
|
|
|
|
npm run build --if-present
|
2019-12-18 19:48:34 +01:00
|
|
|
npm run build-desktop-darwin-nosign
|