Update Microsoft Foundry Models #170
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Update Microsoft Foundry Models | |
| on: | |
| workflow_dispatch: | |
| schedule: | |
| - cron: '0 5 * * *' # Daily at 05:00 UTC | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| generate-and-pr: | |
| runs-on: ubuntu-latest | |
| if: ${{ github.repository_owner == 'microsoft' }} | |
| steps: | |
| - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| - name: Generate updated Microsoft Foundry model descriptors | |
| working-directory: src/Aspire.Hosting.Foundry/tools | |
| run: | | |
| set -e | |
| "$GITHUB_WORKSPACE/dotnet.sh" run GenModel.cs | |
| "$GITHUB_WORKSPACE/dotnet.sh" run GenModel.cs --local | |
| - name: Generate GitHub App Token | |
| id: app-token | |
| uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6 | |
| with: | |
| app-id: ${{ secrets.ASPIRE_BOT_APP_ID }} | |
| private-key: ${{ secrets.ASPIRE_BOT_PRIVATE_KEY }} | |
| - name: Create or update pull request | |
| uses: dotnet/actions-create-pull-request@e8d799aa1f8b17f324f9513832811b0a62f1e0b1 | |
| with: | |
| token: ${{ steps.app-token.outputs.token }} | |
| branch: update-ai-foundry-models | |
| base: main | |
| commit-message: "[Automated] Update Microsoft Foundry Models" | |
| labels: | | |
| area-integrations | |
| area-engineering-systems | |
| title: "[Automated] Update Microsoft Foundry Models" | |
| body: "Auto-generated update of Microsoft Foundry model descriptors (FoundryModel.Generated.cs)." |