admin管理员组

文章数量:1332377

I've been using the following YAML file in GitHub Actions to build my .NET MAUI app and upload it to TestFlight for quite some time without any issues.

I just updated it slightly to use .NET 9 as opposed to .NET 8 and now it's failing in the step that is supposed to download Apple Provisioning Profile with the following error:

Error: error:1E08010C:DECODER routines::unsupported

I think it's related to XCode but haven't figured it out yet. Any idea what maybe causing this and how to fix it?

Here's the YAML file:

name: Build & Publish MyApp iOS

on:
  pull_request:
    branches: [ "master" ]

jobs:
  build-pack-n-ship:

    runs-on: macos-latest

    steps:
    - uses: maxim-lobanov/setup-xcode@v1
      with:
        xcode-version: latest
    - uses: actions/checkout@v3
    - name: Setup .NET
      uses: actions/setup-dotnet@v3
      with:
        dotnet-version: 9.0.x
    - name: Install MAUI workload
      run: dotnet workload install maui
    - name: Import Code-Signing Certificates
      uses: Apple-Actions/import-codesign-certs@v1
      with:
        p12-filepath: 'MyAppleDistributionCert.p12'
        p12-password: ${{ secrets.CERTIFICATES_P12_PASSWORD }}
    - name: Download Apple Provisioning Profiles
      uses: Apple-Actions/download-provisioning-profiles@v1
      with:
        bundle-id: 'com.mycompany.myapp'
        issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
        api-key-id: ${{ secrets.APPSTORE_KEY_ID }}
        api-private-key: ${{ secrets.APPSTORE_PRIVATE_KEY }}
    - name: Restore dependencies
      run: dotnet restore
    - name: Build and Publish
      run: dotnet publish -c Release -f:net9.0-ios /p:ArchiveOnBuild=true /p:EnableAssemblyILStripping=false
    - name: List generated files
      run: ls -l
    - name: Upload Build Artifact
      uses: actions/[email protected]
      with:
        path: '**/*.ipa'
    - name: Archive dSYM files
      run: zip -r dSYMs.zip . -i ./MyApp/bin/Release/net9.0-ios/ios-arm64/*.app.dSYM
    - name: Upload dSYM Artifact
      uses: actions/[email protected]
      with:
        name: dSYMs
        path: '**/dSYMs.zip'
    - name: 'Upload app to TestFlight'
      uses: apple-actions/upload-testflight-build@v1
      with: 
        app-path: './MyApp/bin/Release/net9.0-ios/ios-arm64/publish/MyApp.ipa'
        issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
        api-key-id: ${{ secrets.APPSTORE_KEY_ID }}
        api-private-key: ${{ secrets.APPSTORE_PRIVATE_KEY }}

本文标签: Build NET MAUI 9 app using GitHub ActionsStack Overflow