Skip to content

Commit

Permalink
[releases/24.x] Update AL-Go System Files from microsoft/AL-Go-PTE@pr…
Browse files Browse the repository at this point in the history
…eview - e23536e3e226943446586ba1222608a2025935d7 (#1628)

## preview

Note that when using the preview version of AL-Go for GitHub, we
recommend you Update your AL-Go system files, as soon as possible when
informed that an update is available.

### Issues

- Issue 1105 Increment Version Number - repoVersion in
.github/AL-Go-Settings.json is not updated
- Issue 1073 Publish to AppSource - Automated validation: failure
- Issue 980 Allow Scope to be PTE in continuousDeployment for PTE
extensions in Sandbox (enhancement request)
- Issue 1079 AppSource App deployment failes with PerTenantExtensionCop
Error PTE0001 and PTE0002
- Issue 866 Accessing GitHub Environment Variables in DeployToCustom
Scenarios for PowerShell Scripts
- Issue 1083 SyncMode for custom deployments?
- Issue 1109 Why filter deployment settings?
- Fix issue with github ref when running reusable workflows
- Issue 1098 Support for specifying the name of the AZURE_CREDENTIALS
secret by adding a AZURE_CREDENTIALSSecretName setting
- Fix placeholder syntax for git ref in PullRequestHandler.yaml

### Dependencies to PowerShell modules

AL-Go for GitHub relies on specific PowerShell modules, and the minimum
versions required for these modules are tracked in
[Packages.json](https://raw.githubusercontent.com/microsoft/AL-Go/main/Actions/Packages.json)
file. Should the installed modules on the GitHub runner not meet these
minimum requirements, the necessary modules will be installed as needed.

### Support managed identities and federated credentials

All authentication context secrets now supports managed identities and
federated credentials. See more [here](Scenarios/secrets.md).
Furthermore, you can now use https://aka.ms/algosecrets#authcontext to
learn more about the formatting of that secret.

### Business Central Performance Toolkit Test Result Viewer

In the summary after a Test Run, you now also have the result of
performance tests.

### New Settings

- `deployTo<environmentName>`: is not really new, but has a new
property:

- **Scope** = specifies the scope of the deployment: Dev, PTE. If not
specified, AL-Go for GitHub will always use the Dev Scope for AppSource
Apps, but also for PTEs when deploying to sandbox environments when
impersonation (refreshtoken) is used for authentication.
- **BuildMode** = specifies which buildMode to use for the deployment.
Default is to use the Default buildMode.
- **\<custom>** = custom properties are now supported and will be
transferred to a custom deployment script in the hashtable.

- `bcptThresholds` is a JSON object with properties for the default
thresholds for the Business Central Performance Toolkit

- **DurationWarning** - a warning is issued if the duration of a bcpt
test degrades more than this percentage (default 10)
- **DurationError** - an error is issued if the duration of a bcpt test
degrades more than this percentage (default 25)
- **NumberOfSqlStmtsWarning** - a warning is issued if the number of SQL
statements from a bcpt test increases more than this percentage (default
5)
- **NumberOfSqlStmtsError** - an error is issued if the number of SQL
statements from a bcpt test increases more than this percentage (default
10)

> \[!NOTE\]
> Duration thresholds are subject to varying results depending on the
performance of the agent running the tests. Number of SQL statements
executed by a test is often the most reliable indicator of performance
degredation.

AB#420000

Co-authored-by: bcbuild-github-agent <[email protected]>
  • Loading branch information
bcbuild-github-agent and bcbuild-github-agent authored Jul 25, 2024
1 parent 3f912d1 commit 120c415
Show file tree
Hide file tree
Showing 23 changed files with 100 additions and 98 deletions.
2 changes: 1 addition & 1 deletion .github/AL-Go-Settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,5 +72,5 @@
]
},
"UpdateALGoSystemFilesEnvironment": "Official-Build",
"templateSha": "0aab342a0ddd80612fafbc5149c8e95b3476b12a"
"templateSha": "e23536e3e226943446586ba1222608a2025935d7"
}
2 changes: 2 additions & 0 deletions .github/RELEASENOTES.copy.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Note that when using the preview version of AL-Go for GitHub, we recommend you U
- Issue 1109 Why filter deployment settings?
- Fix issue with github ref when running reusable workflows
- Issue 1098 Support for specifying the name of the AZURE_CREDENTIALS secret by adding a AZURE_CREDENTIALSSecretName setting
- Fix placeholder syntax for git ref in PullRequestHandler.yaml

### Dependencies to PowerShell modules

Expand All @@ -31,6 +32,7 @@ In the summary after a Test Run, you now also have the result of performance tes
- `deployTo<environmentName>`: is not really new, but has a new property:

- **Scope** = specifies the scope of the deployment: Dev, PTE. If not specified, AL-Go for GitHub will always use the Dev Scope for AppSource Apps, but also for PTEs when deploying to sandbox environments when impersonation (refreshtoken) is used for authentication.
- **BuildMode** = specifies which buildMode to use for the deployment. Default is to use the Default buildMode.
- **\<custom>** = custom properties are now supported and will be transferred to a custom deployment script in the hashtable.

- `bcptThresholds` is a JSON object with properties for the default thresholds for the Business Central Performance Toolkit
Expand Down
40 changes: 20 additions & 20 deletions .github/workflows/CICD.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
workflowDepth: ${{ steps.DetermineWorkflowDepth.outputs.WorkflowDepth }}
steps:
- name: Dump Workflow Information
uses: microsoft/AL-Go/Actions/DumpWorkflowInfo@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DumpWorkflowInfo@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

Expand All @@ -56,14 +56,14 @@ jobs:

- name: Initialize the workflow
id: init
uses: microsoft/AL-Go/Actions/WorkflowInitialize@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/WorkflowInitialize@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
eventId: "DO0091"

- name: Read settings
id: ReadSettings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
get: type, powerPlatformSolutionFolder
Expand All @@ -75,7 +75,7 @@ jobs:
- name: Determine Projects To Build
id: determineProjectsToBuild
uses: microsoft/AL-Go/Actions/DetermineProjectsToBuild@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DetermineProjectsToBuild@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
maxBuildDepth: ${{ env.workflowDepth }}
Expand All @@ -88,23 +88,23 @@ jobs:
- name: Determine Delivery Target Secrets
id: DetermineDeliveryTargetSecrets
uses: microsoft/AL-Go/Actions/DetermineDeliveryTargets@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DetermineDeliveryTargets@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
projectsJson: '${{ steps.determineProjectsToBuild.outputs.ProjectsJson }}'
checkContextSecrets: 'false'

- name: Read secrets
id: ReadSecrets
uses: microsoft/AL-Go/Actions/ReadSecrets@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSecrets@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
gitHubSecrets: ${{ toJson(secrets) }}
getSecrets: ${{ steps.DetermineDeliveryTargetSecrets.outputs.ContextSecrets }}

- name: Determine Delivery Targets
id: DetermineDeliveryTargets
uses: microsoft/AL-Go/Actions/DetermineDeliveryTargets@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DetermineDeliveryTargets@fa90994cf0e9dbf357a5316bc079e252fe73b581
env:
Secrets: '${{ steps.ReadSecrets.outputs.Secrets }}'
with:
Expand All @@ -114,7 +114,7 @@ jobs:

- name: Determine Deployment Environments
id: DetermineDeploymentEnvironments
uses: microsoft/AL-Go/Actions/DetermineDeploymentEnvironments@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DetermineDeploymentEnvironments@fa90994cf0e9dbf357a5316bc079e252fe73b581
env:
GITHUB_TOKEN: ${{ github.token }}
with:
Expand All @@ -130,13 +130,13 @@ jobs:
uses: actions/checkout@v4

- name: Read settings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
get: templateUrl

- name: Check for updates to AL-Go system files
uses: microsoft/AL-Go/Actions/CheckForUpdates@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/CheckForUpdates@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
templateUrl: ${{ env.templateUrl }}
Expand Down Expand Up @@ -213,7 +213,7 @@ jobs:
path: '.artifacts'

- name: Read settings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

Expand All @@ -222,7 +222,7 @@ jobs:
uses: actions/configure-pages@v5

- name: Build Reference Documentation
uses: microsoft/AL-Go/Actions/BuildReferenceDocumentation@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/BuildReferenceDocumentation@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
artifacts: '.artifacts'
Expand Down Expand Up @@ -259,7 +259,7 @@ jobs:
path: '.artifacts'

- name: Read settings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: ${{ matrix.shell }}
get: type,powerPlatformSolutionFolder
Expand All @@ -273,15 +273,15 @@ jobs:
- name: Read secrets
id: ReadSecrets
uses: microsoft/AL-Go/Actions/ReadSecrets@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSecrets@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: ${{ matrix.shell }}
gitHubSecrets: ${{ toJson(secrets) }}
getSecrets: '${{ steps.envName.outputs.envName }}-AuthContext,${{ steps.envName.outputs.envName }}_AuthContext,AuthContext'

- name: Deploy to Business Central
id: Deploy
uses: microsoft/AL-Go/Actions/Deploy@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/Deploy@fa90994cf0e9dbf357a5316bc079e252fe73b581
env:
Secrets: '${{ steps.ReadSecrets.outputs.Secrets }}'
with:
Expand All @@ -293,7 +293,7 @@ jobs:

- name: Deploy to Power Platform
if: env.type == 'PTE' && env.powerPlatformSolutionFolder != ''
uses: microsoft/AL-Go/Actions/DeployPowerPlatform@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DeployPowerPlatform@fa90994cf0e9dbf357a5316bc079e252fe73b581
env:
Secrets: '${{ steps.ReadSecrets.outputs.Secrets }}'
with:
Expand Down Expand Up @@ -321,20 +321,20 @@ jobs:
path: '.artifacts'

- name: Read settings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

- name: Read secrets
id: ReadSecrets
uses: microsoft/AL-Go/Actions/ReadSecrets@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSecrets@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
gitHubSecrets: ${{ toJson(secrets) }}
getSecrets: '${{ matrix.deliveryTarget }}Context'

- name: Deliver
uses: microsoft/AL-Go/Actions/Deliver@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/Deliver@fa90994cf0e9dbf357a5316bc079e252fe73b581
env:
Secrets: '${{ steps.ReadSecrets.outputs.Secrets }}'
with:
Expand All @@ -354,7 +354,7 @@ jobs:

- name: Finalize the workflow
id: PostProcess
uses: microsoft/AL-Go/Actions/WorkflowPostProcess@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/WorkflowPostProcess@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
eventId: "DO0091"
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/DeployReferenceDocumentation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,19 +30,19 @@ jobs:

- name: Initialize the workflow
id: init
uses: microsoft/AL-Go/Actions/WorkflowInitialize@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/WorkflowInitialize@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
eventId: "DO0097"

- name: Read settings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

- name: Determine Deployment Environments
id: DetermineDeploymentEnvironments
uses: microsoft/AL-Go/Actions/DetermineDeploymentEnvironments@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DetermineDeploymentEnvironments@fa90994cf0e9dbf357a5316bc079e252fe73b581
env:
GITHUB_TOKEN: ${{ github.token }}
with:
Expand All @@ -55,7 +55,7 @@ jobs:
uses: actions/configure-pages@v5

- name: Build Reference Documentation
uses: microsoft/AL-Go/Actions/BuildReferenceDocumentation@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/BuildReferenceDocumentation@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
artifacts: 'latest'
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/IncrementVersionNumber.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
runs-on: [ windows-latest ]
steps:
- name: Dump Workflow Information
uses: microsoft/AL-Go/Actions/DumpWorkflowInfo@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DumpWorkflowInfo@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

Expand All @@ -49,27 +49,27 @@ jobs:

- name: Initialize the workflow
id: init
uses: microsoft/AL-Go/Actions/WorkflowInitialize@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/WorkflowInitialize@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
eventId: "DO0096"

- name: Read settings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

- name: Read secrets
id: ReadSecrets
uses: microsoft/AL-Go/Actions/ReadSecrets@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSecrets@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
gitHubSecrets: ${{ toJson(secrets) }}
getSecrets: 'TokenForPush'
useGhTokenWorkflowForPush: '${{ github.event.inputs.useGhTokenWorkflow }}'

- name: Increment Version Number
uses: microsoft/AL-Go/Actions/IncrementVersionNumber@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/IncrementVersionNumber@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
token: ${{ steps.ReadSecrets.outputs.TokenForPush }}
Expand All @@ -80,7 +80,7 @@ jobs:

- name: Finalize the workflow
if: always()
uses: microsoft/AL-Go/Actions/WorkflowPostProcess@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/WorkflowPostProcess@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
eventId: "DO0096"
Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/PullRequestHandler.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
if: (github.event.pull_request.base.repo.full_name != github.event.pull_request.head.repo.full_name) && (github.event_name != 'pull_request')
runs-on: windows-latest
steps:
- uses: microsoft/AL-Go/Actions/VerifyPRChanges@5eeeec54ab7e6a9d97701effe420ef74bda08c67
- uses: microsoft/AL-Go/Actions/VerifyPRChanges@fa90994cf0e9dbf357a5316bc079e252fe73b581

Initialization:
needs: [ PregateCheck ]
Expand All @@ -45,26 +45,26 @@ jobs:
workflowDepth: ${{ steps.DetermineWorkflowDepth.outputs.WorkflowDepth }}
steps:
- name: Dump Workflow Information
uses: microsoft/AL-Go/Actions/DumpWorkflowInfo@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DumpWorkflowInfo@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

- name: Checkout
uses: actions/checkout@v4
with:
lfs: true
ref: ${{ github.event_name == 'pull_request' && github.sha || format('refs/pull/${0}/merge', github.event.pull_request.number) }}
ref: ${{ github.event_name == 'pull_request' && github.sha || format('refs/pull/{0}/merge', github.event.pull_request.number) }}

- name: Initialize the workflow
id: init
uses: microsoft/AL-Go/Actions/WorkflowInitialize@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/WorkflowInitialize@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
eventId: "DO0104"

- name: Read settings
id: ReadSettings
uses: microsoft/AL-Go/Actions/ReadSettings@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/ReadSettings@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell

Expand All @@ -75,7 +75,7 @@ jobs:
- name: Determine Projects To Build
id: determineProjectsToBuild
uses: microsoft/AL-Go/Actions/DetermineProjectsToBuild@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/DetermineProjectsToBuild@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
maxBuildDepth: ${{ env.workflowDepth }}
Expand All @@ -93,7 +93,7 @@ jobs:
with:
shell: ${{ needs.Initialization.outputs.githubRunnerShell }}
runsOn: ${{ needs.Initialization.outputs.githubRunner }}
checkoutRef: ${{ github.event_name == 'pull_request' && github.sha || format('refs/pull/${0}/merge', github.event.pull_request.number) }}
checkoutRef: ${{ github.event_name == 'pull_request' && github.sha || format('refs/pull/{0}/merge', github.event.pull_request.number) }}
parentTelemetryScopeJson: ${{ needs.Initialization.outputs.telemetryScopeJson }}
project: ${{ matrix.project }}
projectName: ${{ matrix.projectName }}
Expand All @@ -117,7 +117,7 @@ jobs:
with:
shell: ${{ needs.Initialization.outputs.githubRunnerShell }}
runsOn: ${{ needs.Initialization.outputs.githubRunner }}
checkoutRef: ${{ github.event_name == 'pull_request' && github.sha || format('refs/pull/${0}/merge', github.event.pull_request.number) }}
checkoutRef: ${{ github.event_name == 'pull_request' && github.sha || format('refs/pull/{0}/merge', github.event.pull_request.number) }}
parentTelemetryScopeJson: ${{ needs.Initialization.outputs.telemetryScopeJson }}
project: ${{ matrix.project }}
projectName: ${{ matrix.projectName }}
Expand All @@ -136,7 +136,7 @@ jobs:
steps:
- name: Pull Request Status Check
id: PullRequestStatusCheck
uses: microsoft/AL-Go/Actions/PullRequestStatusCheck@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/PullRequestStatusCheck@fa90994cf0e9dbf357a5316bc079e252fe73b581
env:
GITHUB_TOKEN: ${{ github.token }}
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/Troubleshooting.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
lfs: true

- name: Troubleshooting
uses: microsoft/AL-Go/Actions/Troubleshooting@5eeeec54ab7e6a9d97701effe420ef74bda08c67
uses: microsoft/AL-Go/Actions/Troubleshooting@fa90994cf0e9dbf357a5316bc079e252fe73b581
with:
shell: powershell
gitHubSecrets: ${{ toJson(secrets) }}
Expand Down
Loading

0 comments on commit 120c415

Please sign in to comment.