Skip to content

Update dependency Microsoft.NET.Test.Sdk to v17.11.0 (#515) #477

Update dependency Microsoft.NET.Test.Sdk to v17.11.0 (#515)

Update dependency Microsoft.NET.Test.Sdk to v17.11.0 (#515) #477

Workflow file for this run

name: Scaler
on:
push:
branches: [ main ]
paths-ignore:
- '**.md'
jobs:
build:
name: Build
runs-on: windows-latest
outputs:
chartVersion: ${{ steps.chart.outputs.chartVersion }}
imageTag: ${{ steps.chart.outputs.imageTag }}
permissions:
id-token: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Read Versions
id: chart
uses: ./.github/actions/parse-chart
- name: Build Scaler
uses: ./.github/actions/dotnet-publish
with:
assemblyVersion: ${{ steps.chart.outputs.assemblyVersion }}
azureClientId: ${{ secrets.AZURE_CLIENT_ID }}
azureCodeSigningAccountName: ${{ secrets.AZURE_CODESIGNING_NAME }}
azureSubscriptionId: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
azureTenantId: ${{ secrets.AZURE_TENANT_ID }}
buildConfiguration: Release
certificateProfileName: ${{ secrets.AZURE_CODESIGNING_PROFILE_NAME }}
fileVersion: ${{ steps.chart.outputs.assemblyFileVersion }}
repositoryUri: ${{ github.server_url }}/${{ github.repository }}
sign: 'true'
testResultsDirectory: ${{ runner.temp }}/TestResults
- name: Upload Code Coverage
uses: ./.github/actions/code-coverage
with:
codecovToken: ${{ secrets.CODECOV_TOKEN }}
reportPath: ${{ runner.temp }}/TestResults/*/coverage.cobertura.xml
validate:
name: Validate
runs-on: ubuntu-latest
needs: build
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Build Docker Image
uses: ./.github/actions/docker-build
with:
copyBinaries: 'true'
imageRepository: ghcr.io/${{ github.repository }}
imageTag: ${{ needs.build.outputs.imageTag }}
- name: Validate Helm Chart
uses: ./.github/actions/helm-test
with:
buildConfiguration: Release
imageTag: ${{ needs.build.outputs.imageTag }}
scalerImageRepository: ghcr.io/${{ github.repository }}
- name: Pack Helm Chart
uses: ./.github/actions/helm-package
with:
chartPath: ${{ github.workspace }}/charts/durabletask-azurestorage-scaler
chartVersion: ${{ needs.build.outputs.chartVersion }}
gpgPassword: ${{ secrets.GPG_PASSWORD }}
gpgPrivateKey: ${{ secrets.GPG_PRIVATE_KEY_BASE64 }}
sign: 'true'
publishImage:
name: Publish Image
runs-on: ubuntu-latest
needs: validate
permissions:
contents: write
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download Image
uses: actions/download-artifact@v4
with:
name: image
path: ${{ runner.temp }}/image
- name: Read Versions
id: chart
uses: ./.github/actions/parse-chart
- name: Push Docker Image
id: push
uses: ./.github/actions/docker-push
with:
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
imageArchive: ${{ runner.temp }}/image/durabletask-azurestorage-scaler-${{ steps.chart.outputs.imageTag }}.tar
imageRepository: ghcr.io/${{ github.repository }}
imageTag: ${{ steps.chart.outputs.imageTag }}
pushLatest: ${{ steps.chart.outputs.imagePrerelease != 'true' }}
- name: Create Image Release
uses: ./.github/actions/github-release
if: ${{ steps.push.outputs.success == 'true' }}
with:
asset: ${{ runner.temp }}/image/durabletask-azurestorage-scaler-${{ steps.chart.outputs.imageTag }}.tar
name: 'Durable Task KEDA External Scaler Image'
prerelease: ${{ steps.chart.outputs.imagePrerelease }}
tag: 'Image_${{ steps.chart.outputs.imageTag }}.${{ steps.push.outputs.digest }}'
version: '${{ steps.chart.outputs.imageTag }}.${{ steps.push.outputs.digest }}'
publishChart:
name: Publish Chart
runs-on: ubuntu-latest
needs: publishImage
permissions:
contents: write
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download Chart
uses: actions/download-artifact@v4
with:
name: chart
path: ${{ runner.temp }}/chart
- name: Read Versions
id: chart
uses: ./.github/actions/parse-chart
- name: Sync Chart
id: sync
uses: ./.github/actions/chart-sync
with:
assetPath: ${{ runner.temp }}/chart
chartRepositoryDirectoryName: 'releases'
chartRepositoryToken: ${{ secrets.CHART_REPO_PAT }}
chartVersion: ${{ steps.chart.outputs.chartVersion }}
logoPath: ${{ github.workspace }}/img/storm-icon.png
readmePath: ${{ github.workspace }}/charts/durabletask-azurestorage-scaler/README.md
- name: Create Chart Release
uses: ./.github/actions/github-release
if: ${{ steps.sync.outputs.success == 'true' }}
with:
asset: ${{ runner.temp }}/chart
name: 'Durable Task KEDA External Scaler Chart'
prerelease: ${{ steps.chart.outputs.chartPrerelease }}
tag: 'Chart_${{ steps.chart.outputs.chartVersion }}'
version: ${{ steps.chart.outputs.chartVersion }}