From 26e1520b7f8183f9e3e45bd82f600da1fec559e3 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Mon, 27 Jan 2025 16:18:32 -0800 Subject: Backport tag-release token fix to release/2024.12-ForeverFPS branch --- .github/workflows/tag-release.yaml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/tag-release.yaml b/.github/workflows/tag-release.yaml index 65d1d43a83..24ee2de794 100644 --- a/.github/workflows/tag-release.yaml +++ b/.github/workflows/tag-release.yaml @@ -37,7 +37,12 @@ jobs: - name: Update Tag uses: actions/github-script@v7.0.1 with: - github-token: ${{ secrets.GITHUB_TOKEN }} + # use a real access token instead of GITHUB_TOKEN default. + # required so that the results of this tag creation can trigger the build workflow + # https://stackoverflow.com/a/71372524 + # https://docs.github.com/en/actions/using-workflows/triggering-a-workflow#triggering-a-workflow-from-a-workflow + # this token will need to be renewed anually in January + github-token: ${{ secrets.LL_TAG_RELEASE_TOKEN }} script: | github.rest.git.createRef({ owner: context.repo.owner, -- cgit v1.3 From 34c3eed88ab21bf3c8419a051dfc41853a831ca7 Mon Sep 17 00:00:00 2001 From: Andrey Lihatskiy Date: Thu, 13 Feb 2025 17:40:40 +0200 Subject: Bump macos runner to os version 15 with xcode 16.1 --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 7d6bcd2bc4..60ad7e8fe5 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -42,7 +42,7 @@ jobs: needs: setup strategy: matrix: - runner: [windows-large, macos-12-large] + runner: [windows-large, macos-15-xlarge] configuration: ${{ fromJSON(needs.setup.outputs.configurations) }} runs-on: ${{ matrix.runner }} outputs: @@ -64,7 +64,7 @@ jobs: # autobuild-package.xml. AUTOBUILD_VCS_INFO: "true" AUTOBUILD_VSVER: "170" - DEVELOPER_DIR: "/Applications/Xcode_14.0.1.app/Contents/Developer" + DEVELOPER_DIR: "/Applications/Xcode_16.1.app/Contents/Developer" # Ensure that Linden viewer builds engage Bugsplat. BUGSPLAT_DB: ${{ needs.setup.outputs.bugsplat_db }} build_coverity: false -- cgit v1.3 From a1121eb8c0cf3074c769773cbac42482936916e2 Mon Sep 17 00:00:00 2001 From: "Jonathan \"Geenz\" Goodman" Date: Wed, 19 Feb 2025 15:00:26 -0500 Subject: Update allow list for CLA. --- .github/workflows/cla.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/cla.yaml b/.github/workflows/cla.yaml index 013adc9ca8..19d325935d 100644 --- a/.github/workflows/cla.yaml +++ b/.github/workflows/cla.yaml @@ -23,4 +23,4 @@ jobs: path-to-signatures: signatures.json remote-organization-name: secondlife remote-repository-name: cla-signatures - allowlist: callum@mbp.localdomain + allowlist: [callum@mbp.localdomain, rye@lindenlab.com] -- cgit v1.3 From 1fe6031a12f54c530e6afbc911fc7bee8f9f013f Mon Sep 17 00:00:00 2001 From: "Jonathan \"Geenz\" Goodman" Date: Wed, 19 Feb 2025 15:14:50 -0500 Subject: CLA wants a comma separated string. --- .github/workflows/cla.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/cla.yaml b/.github/workflows/cla.yaml index 19d325935d..7866f943b5 100644 --- a/.github/workflows/cla.yaml +++ b/.github/workflows/cla.yaml @@ -23,4 +23,4 @@ jobs: path-to-signatures: signatures.json remote-organization-name: secondlife remote-repository-name: cla-signatures - allowlist: [callum@mbp.localdomain, rye@lindenlab.com] + allowlist: callum@mbp.localdomain,rye@lindenlab.com -- cgit v1.3 From 3c96bd2c69865cba00a7e8f30afde23d2dadce78 Mon Sep 17 00:00:00 2001 From: "Jonathan \"Geenz\" Goodman" Date: Fri, 21 Mar 2025 05:54:08 -0400 Subject: Switch to smaller runners (#3722) * Switch to smaller runners * Make the runner conditional based upon a specific tag. Co-authored-by: Andrey Lihatskiy --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 60ad7e8fe5..50b0cf02bc 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -42,8 +42,8 @@ jobs: needs: setup strategy: matrix: - runner: [windows-large, macos-15-xlarge] - configuration: ${{ fromJSON(needs.setup.outputs.configurations) }} + runner: ${{ fromJson((github.ref_type == 'tag' && startsWith(github.ref, 'refs/tags/Second_Life')) && '["windows-large","macos-15-xlarge"]' || '["windows-latest","macos-15"]') }} + configuration: ${{ fromJson(needs.setup.outputs.configurations) }} runs-on: ${{ matrix.runner }} outputs: viewer_channel: ${{ steps.build.outputs.viewer_channel }} -- cgit v1.3 From 1e2d4d3018f0e0c46e4f22943ae51badd9aaaaf8 Mon Sep 17 00:00:00 2001 From: AtlasLinden <114031241+AtlasLinden@users.noreply.github.com> Date: Wed, 26 Mar 2025 14:41:44 -0700 Subject: Added QA workflow file Previously in the develop archive. Recent change is to only run the workflow for tagged builds. The code to running other builds has been commented out. --- .github/workflows/qatest.yaml | 172 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 172 insertions(+) create mode 100644 .github/workflows/qatest.yaml (limited to '.github/workflows') diff --git a/.github/workflows/qatest.yaml b/.github/workflows/qatest.yaml new file mode 100644 index 0000000000..8709ca0cd4 --- /dev/null +++ b/.github/workflows/qatest.yaml @@ -0,0 +1,172 @@ +name: Run QA Test # Runs automated tests on a self-hosted QA machine + +on: + workflow_run: + workflows: ["Build"] + types: + - completed + +concurrency: + group: qa-test-run + cancel-in-progress: true # Cancels any queued job when a new one starts + +jobs: + debug-workflow: + runs-on: ubuntu-latest + steps: + - name: Debug Workflow Variables + run: | + echo "Workflow Conclusion: ${{ github.event.workflow_run.conclusion }}" + echo "Workflow Head Branch: ${{ github.event.workflow_run.head_branch }}" + echo "Workflow Run ID: ${{ github.event.workflow_run.id }}" + echo "Head Commit Message: ${{ github.event.workflow_run.head_commit.message }}" + echo "GitHub Ref: ${{ github.ref }}" + echo "GitHub Ref Name: ${{ github.ref_name }}" + echo "GitHub Event Name: ${{ github.event_name }}" + echo "GitHub Workflow Name: ${{ github.workflow }}" + + install-viewer-and-run-tests: + runs-on: [self-hosted, qa-machine] + # Run test only on successful builds of develop or Second_Life_X branches + if: > + github.event.workflow_run.conclusion == 'success' && + ( + startsWith(github.ref, 'refs/tags/Second_Life') + + # For now this will only run on Second_Life_X tagged builds + # || startsWith(github.event.workflow_run.head_branch, 'release') + # || github.event.workflow_run.head_branch == 'develop' + ) + + steps: + - name: Temporarily Allow PowerShell Scripts (Process Scope) + run: | + Set-ExecutionPolicy RemoteSigned -Scope Process -Force + + - name: Verify viewer-sikulix-main Exists + run: | + if (-Not (Test-Path -Path 'C:\viewer-sikulix-main')) { + Write-Host '❌ Error: viewer-sikulix not found on runner!' + exit 1 + } + Write-Host '✅ viewer-sikulix is already available.' + + - name: Fetch & Download Windows Installer Artifact + shell: pwsh + run: | + $BUILD_ID = "${{ github.event.workflow_run.id }}" + $ARTIFACTS_URL = "https://api.github.com/repos/secondlife/viewer/actions/runs/$BUILD_ID/artifacts" + + # Fetch the correct artifact URL + $response = Invoke-RestMethod -Headers @{Authorization="token ${{ secrets.GITHUB_TOKEN }}" } -Uri $ARTIFACTS_URL + $ARTIFACT_NAME = ($response.artifacts | Where-Object { $_.name -eq "Windows-installer" }).archive_download_url + + if (-Not $ARTIFACT_NAME) { + Write-Host "❌ Error: Windows-installer artifact not found!" + exit 1 + } + + Write-Host "✅ Artifact found: $ARTIFACT_NAME" + + # Secure download path + $DownloadPath = "$env:TEMP\secondlife-build-$BUILD_ID" + New-Item -ItemType Directory -Path $DownloadPath -Force | Out-Null + $InstallerPath = "$DownloadPath\installer.zip" + + # Download the ZIP + Invoke-WebRequest -Uri $ARTIFACT_NAME -Headers @{Authorization="token ${{ secrets.GITHUB_TOKEN }}"} -OutFile $InstallerPath + + # Ensure download succeeded + if (-Not (Test-Path $InstallerPath)) { + Write-Host "❌ Error: Failed to download Windows-installer.zip" + exit 1 + } + + - name: Extract Installer & Locate Executable + shell: pwsh + run: | + # Explicitly set BUILD_ID again (since it does not appear to persist across steps) + $BUILD_ID = "${{ github.event.workflow_run.id }}" + $ExtractPath = "$env:TEMP\secondlife-build-$BUILD_ID" + $InstallerZip = "$ExtractPath\installer.zip" + + # Print paths for debugging + Write-Host "Extract Path: $ExtractPath" + Write-Host "Installer ZIP Path: $InstallerZip" + + # Verify ZIP exists before extracting + if (-Not (Test-Path $InstallerZip)) { + Write-Host "❌ Error: ZIP file not found at $InstallerZip!" + exit 1 + } + + Write-Host "✅ ZIP file exists and is valid. Extracting..." + + Expand-Archive -Path $InstallerZip -DestinationPath $ExtractPath -Force + + # Find installer executable + $INSTALLER_PATH = (Get-ChildItem -Path $ExtractPath -Filter '*.exe' -Recurse | Select-Object -First 1).FullName + + if (-Not $INSTALLER_PATH -or $INSTALLER_PATH -eq "") { + Write-Host "❌ Error: No installer executable found in the extracted files!" + Write-Host "📂 Extracted Files:" + Get-ChildItem -Path $ExtractPath -Recurse | Format-Table -AutoSize + exit 1 + } + + Write-Host "✅ Installer found: $INSTALLER_PATH" + echo "INSTALLER_PATH=$INSTALLER_PATH" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Install Second Life Using Task Scheduler (Bypass UAC) + shell: pwsh + run: | + $action = New-ScheduledTaskAction -Execute "${{ env.INSTALLER_PATH }}" -Argument "/S" + $principal = New-ScheduledTaskPrincipal -UserId "SYSTEM" -LogonType ServiceAccount -RunLevel Highest + $task = New-ScheduledTask -Action $action -Principal $principal + Register-ScheduledTask -TaskName "SilentSLInstaller" -InputObject $task -Force + Start-ScheduledTask -TaskName "SilentSLInstaller" + + - name: Wait for Installation to Complete + shell: pwsh + run: | + Write-Host "Waiting for the Second Life installer to finish..." + do { + Start-Sleep -Seconds 5 + $installerProcess = Get-Process | Where-Object { $_.Path -eq "${{ env.INSTALLER_PATH }}" } + } while ($installerProcess) + + Write-Host "✅ Installation completed!" + + - name: Cleanup Task Scheduler Entry + shell: pwsh + run: | + Unregister-ScheduledTask -TaskName "SilentSLInstaller" -Confirm:$false + Write-Host "✅ Task Scheduler entry removed." + + - name: Delete Installer ZIP + shell: pwsh + run: | + # Explicitly set BUILD_ID again + $BUILD_ID = "${{ github.event.workflow_run.id }}" + $DeletePath = "$env:TEMP\secondlife-build-$BUILD_ID\installer.zip" + + Write-Host "Checking if installer ZIP exists: $DeletePath" + + # Ensure the ZIP file exists before trying to delete it + if (Test-Path $DeletePath) { + Remove-Item -Path $DeletePath -Force + Write-Host "✅ Successfully deleted: $DeletePath" + } else { + Write-Host "⚠️ Warning: ZIP file does not exist, skipping deletion." + } + + - name: Run QA Test Script + run: | + Write-Host "Running QA Test script..." + python C:\viewer-sikulix-main\runTests.py + + # - name: Upload Test Results + # uses: actions/upload-artifact@v3 + # with: + # name: test-results + # path: C:\viewer-sikulix-main\regressionTest\test_results.html \ No newline at end of file -- cgit v1.3 From 51f5b853608a756ef9eb39f5bafd963d28e752d7 Mon Sep 17 00:00:00 2001 From: AtlasLinden <114031241+AtlasLinden@users.noreply.github.com> Date: Thu, 27 Mar 2025 06:58:07 -0700 Subject: Removed unnecessary comments in QA workflow file GHA does not like comments inside an if statement. These have been removed. --- .github/workflows/qatest.yaml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/qatest.yaml b/.github/workflows/qatest.yaml index 8709ca0cd4..533635c3f7 100644 --- a/.github/workflows/qatest.yaml +++ b/.github/workflows/qatest.yaml @@ -27,15 +27,11 @@ jobs: install-viewer-and-run-tests: runs-on: [self-hosted, qa-machine] - # Run test only on successful builds of develop or Second_Life_X branches + # Run test only on successful builds of Second_Life_X branches if: > github.event.workflow_run.conclusion == 'success' && ( startsWith(github.ref, 'refs/tags/Second_Life') - - # For now this will only run on Second_Life_X tagged builds - # || startsWith(github.event.workflow_run.head_branch, 'release') - # || github.event.workflow_run.head_branch == 'develop' ) steps: @@ -169,4 +165,4 @@ jobs: # uses: actions/upload-artifact@v3 # with: # name: test-results - # path: C:\viewer-sikulix-main\regressionTest\test_results.html \ No newline at end of file + # path: C:\viewer-sikulix-main\regressionTest\test_results.html -- cgit v1.3 From 0a39fe8dc9c5f3c24392f3f5cfb385379f70da03 Mon Sep 17 00:00:00 2001 From: AtlasLinden <114031241+AtlasLinden@users.noreply.github.com> Date: Thu, 27 Mar 2025 15:28:15 -0700 Subject: Allow QA workflow to run on Second_Life_X branches Using the echos from the last run, it appears that the tagged builds have Workflow Head Branch = Second_Life_X. Edit made so the file looks for this rather than what was there previously. --- .github/workflows/qatest.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/qatest.yaml b/.github/workflows/qatest.yaml index 533635c3f7..7f3a5242e9 100644 --- a/.github/workflows/qatest.yaml +++ b/.github/workflows/qatest.yaml @@ -31,7 +31,7 @@ jobs: if: > github.event.workflow_run.conclusion == 'success' && ( - startsWith(github.ref, 'refs/tags/Second_Life') + startsWith(github.event.workflow_run.head_branch, 'Second_Life') ) steps: -- cgit v1.3 From 1f3ba13a632a751cc3217cbe02d8aa2190df6b41 Mon Sep 17 00:00:00 2001 From: Brad Linden <46733234+brad-linden@users.noreply.github.com> Date: Mon, 28 Apr 2025 10:51:47 -0700 Subject: Attempt to fix qatest.yaml CodeQL issues (#3987) --- .github/workflows/.gitattributes | 1 + .github/workflows/qatest.yaml | 10 ++++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/.gitattributes (limited to '.github/workflows') diff --git a/.github/workflows/.gitattributes b/.github/workflows/.gitattributes new file mode 100644 index 0000000000..6dc1cca42a --- /dev/null +++ b/.github/workflows/.gitattributes @@ -0,0 +1 @@ +qatest.yaml -text eol=crlf diff --git a/.github/workflows/qatest.yaml b/.github/workflows/qatest.yaml index 7f3a5242e9..4892cfaae3 100644 --- a/.github/workflows/qatest.yaml +++ b/.github/workflows/qatest.yaml @@ -1,4 +1,7 @@ name: Run QA Test # Runs automated tests on a self-hosted QA machine +permissions: + contents: read + #pull-requests: write # maybe need to re-add this later on: workflow_run: @@ -15,11 +18,14 @@ jobs: runs-on: ubuntu-latest steps: - name: Debug Workflow Variables + env: + HEAD_BRANCH: ${{ github.event.workflow_run.head_branch }} + HEAD_COMMIT_MSG: ${{ github.event.workflow_run.head_commit.message }} run: | echo "Workflow Conclusion: ${{ github.event.workflow_run.conclusion }}" - echo "Workflow Head Branch: ${{ github.event.workflow_run.head_branch }}" + echo "Workflow Head Branch: $HEAD_BRANCH" echo "Workflow Run ID: ${{ github.event.workflow_run.id }}" - echo "Head Commit Message: ${{ github.event.workflow_run.head_commit.message }}" + echo "Head Commit Message: $HEAD_COMMIT_MSG" echo "GitHub Ref: ${{ github.ref }}" echo "GitHub Ref Name: ${{ github.ref_name }}" echo "GitHub Event Name: ${{ github.event_name }}" -- cgit v1.3