Skip to content

Commit

Permalink
ci: sign MacOs Dashmate release (#890)
Browse files Browse the repository at this point in the history
  • Loading branch information
Konstantin Shuplenkov authored and markin-io committed Apr 26, 2023
1 parent 9cca6ad commit 227971e
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
25 changes: 25 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -794,6 +794,29 @@ jobs:
colima start
echo "/usr/local/opt/llvm/bin" >> $GITHUB_PATH
- name: Install the Apple certificate
if: runner.os == 'macOS'
env:
BUILD_CERTIFICATE_BASE64: ${{ secrets.MACOS_BUILD_CERTIFICATE_BASE64 }}
P12_PASSWORD: ${{ secrets.MACOS_P12_PASSWORD }}
KEYCHAIN_PASSWORD: ${{ secrets.MACOS_KEYCHAIN_PASSWORD }}
run: |
# create variables
CERTIFICATE_PATH=$RUNNER_TEMP/build_certificate.p12
KEYCHAIN_PATH=$RUNNER_TEMP/app-signing.keychain-db
# import certificate and provisioning profile from secrets
echo -n "$BUILD_CERTIFICATE_BASE64" | base64 --decode -o $CERTIFICATE_PATH
# create temporary keychain
security create-keychain -p "$KEYCHAIN_PASSWORD" $KEYCHAIN_PATH
security set-keychain-settings -lut 21600 $KEYCHAIN_PATH
security unlock-keychain -p "$KEYCHAIN_PASSWORD" $KEYCHAIN_PATH
# import certificate to keychain
security import $CERTIFICATE_PATH -P "$P12_PASSWORD" -A -t cert -f pkcs12 -k $KEYCHAIN_PATH
security list-keychain -d user -s $KEYCHAIN_PATH
- name: Install Linux build deps
if: runner.os == 'Linux'
run: sudo apt-get install -y nsis
Expand Down Expand Up @@ -827,6 +850,8 @@ jobs:
CARGO_BUILD_PROFILE: release

- name: Create package
env:
OSX_KEYCHAIN: $RUNNER_TEMP/app-signing.keychain-db
run: "${GITHUB_WORKSPACE}/scripts/pack_dashmate.sh ${{ matrix.package_type }}"

- name: Upload artifacts to action summary
Expand Down
3 changes: 2 additions & 1 deletion packages/dashmate/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@
"commands": "./src/commands",
"bin": "dashmate",
"macos": {
"identifier": "org.dash.dashmate"
"identifier": "org.dash.dashmate",
"sign": "'Developer ID Installer: The Dash Foundation, Inc.'"
},
"deb": {
"dependencies": "docker-ce (>= 20.10.0) | docker.io (>= 20.10.0)"
Expand Down

0 comments on commit 227971e

Please sign in to comment.