@@ -188,91 +188,20 @@ jobs:
188188 # Notarization will be done manually in a separate step
189189 SIGNING_IDENTITY : " ${{ secrets.APPLE_SIGNING_IDENTITY }}"
190190
191- - name : Ensure all binaries are signed (fallback)
192- env :
193- APPLE_SIGNING_IDENTITY : " ${{ secrets.APPLE_SIGNING_IDENTITY }}"
194- run : |
195- set -e
196- SIGN_ID="${APPLE_SIGNING_IDENTITY}"
197- APP_BUNDLE="./alloomi/apps/web/src-tauri/target/release/bundle/macos/Alloomi.app"
198-
199- echo "🔐 Fallback: Signing all binaries in $APP_BUNDLE"
200- echo " Using SIGN_ID: $SIGN_ID"
201-
202- # Remove extended attributes from all binaries
203- find "$APP_BUNDLE" -type f \( -name "*.node" -o -name "*.dylib" \) -print0 | xargs -0 xattr -cr 2>/dev/null || true
204-
205- # Sign all .node files with Developer ID, timestamp, and hardened runtime
206- # But skip cli-bundle/node which is already signed by bundle-runtime.sh
207- echo " Signing .node files..."
208- find "$APP_BUNDLE" -type f -name "*.node" -not -path "*/cli-bundle/*" -print0 | xargs -0 codesign --force --sign "$SIGN_ID" --options runtime --timestamp || true
209-
210- # Sign all .dylib files with Developer ID, timestamp, and hardened runtime
211- echo " Signing .dylib files..."
212- find "$APP_BUNDLE" -type f -name "*.dylib" -print0 | xargs -0 codesign --force --sign "$SIGN_ID" --options runtime --timestamp || true
213-
214- # Sign specific problematic executables with Developer ID, timestamp, and hardened runtime
215- # Skip cli-bundle/* as they are already signed by bundle-runtime.sh
216- echo " Signing specific executables..."
217- for exe in \
218- "$APP_BUNDLE/Contents/Resources/_up_/cli-bundle/vendor/ripgrep/arm64-darwin/rg" \
219- "$APP_BUNDLE/Contents/Resources/_up_/.next/standalone/apps/web/cli-bundle/vendor/ripgrep/arm64-darwin/rg"
220- do
221- if [ -f "$exe" ]; then
222- echo " Signing: $exe"
223- xattr -cr "$exe" 2>/dev/null || true
224- codesign --force --sign "$SIGN_ID" --options runtime --timestamp "$exe"
225- fi
226- done
227-
228- # Verify signatures
229- echo " Verifying signatures..."
230- for file in \
231- "$APP_BUNDLE/Contents/Resources/_up_/.next/standalone/apps/web/cli-bundle/vendor/ripgrep/arm64-darwin/rg"
232- do
233- if [ -f "$file" ]; then
234- echo " Verifying: $file"
235- codesign -dv "$file" 2>&1 | head -10
236- fi
237- done
238-
239- echo "✅ Fallback signing complete"
240-
241- - name : Sign app bundle with Developer ID (skip cli-bundle)
191+ - name : Sign app bundle with Developer ID
242192 env :
243193 APPLE_SIGNING_IDENTITY : " ${{ secrets.APPLE_SIGNING_IDENTITY }}"
244194 run : |
245195 APP_BUNDLE="./alloomi/apps/web/src-tauri/target/release/bundle/macos/Alloomi.app"
246196 echo "Signing app bundle: $APP_BUNDLE"
247197
248- # Move cli-bundle out temporarily
249- mv "$APP_BUNDLE/Contents/Resources/_up_/cli-bundle" /tmp/cli-bundle-backup || true
250-
251- # Deep sign the app bundle (without cli-bundle)
198+ # Sign the entire app bundle (including cli-bundle) with Developer ID
199+ # Don't move cli-bundle - just sign everything together
252200 codesign --deep --force --sign "$APPLE_SIGNING_IDENTITY" --options runtime --timestamp "$APP_BUNDLE"
253201
254- # Move cli-bundle back
255- mv /tmp/cli-bundle-backup "$APP_BUNDLE/Contents/Resources/_up_/cli-bundle" || true
256-
257- # Sign Node.js with entitlements to allow execution
258- # This is required for Developer ID signed Node.js to work
259- cat > /tmp/node-entitlements.xml << 'EOF'
260- <?xml version="1.0" encoding="UTF-8"?>
261- <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
262- <plist version="1.0">
263- <dict>
264- <key>com.apple.security.cs.allow-unsigned-executable-memory</key>
265- <true/>
266- <key>com.apple.security.cs.disable-library-validation</key>
267- <true/>
268- </dict>
269- </plist>
270- EOF
271- codesign --force --sign "$APPLE_SIGNING_IDENTITY" --options runtime --entitlements /tmp/node-entitlements.xml "$APP_BUNDLE/Contents/Resources/_up_/cli-bundle/node"
272-
273202 echo "✅ App bundle signed"
274203
275- - name : Create DMG manually from signed app bundle
204+ - name : Create DMG
276205 run : |
277206 # Remove old DMG
278207 rm -f ./alloomi/apps/web/src-tauri/target/release/bundle/dmg/Alloomi*.dmg
@@ -301,18 +230,6 @@ jobs:
301230
302231 echo "✅ DMG created from signed app bundle"
303232
304- - name : Sign DMG with Developer ID
305- env :
306- APPLE_SIGNING_IDENTITY : " ${{ secrets.APPLE_SIGNING_IDENTITY }}"
307- run : |
308- DMG_PATH=$(ls ./alloomi/apps/web/src-tauri/target/release/bundle/dmg/Alloomi*.dmg)
309- echo "Signing DMG with Developer ID: $DMG_PATH"
310- # Re-sign the DMG with Developer ID certificate
311- codesign --force --sign "$APPLE_SIGNING_IDENTITY" --options runtime --timestamp "$DMG_PATH"
312- # Verify the signature
313- codesign -dv "$DMG_PATH" 2>&1 | head -5
314- echo "✅ DMG re-signed"
315-
316233 - name : Notarize DMG
317234 timeout-minutes : 60
318235 run : |
0 commit comments