-
-
Notifications
You must be signed in to change notification settings - Fork 330
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
832 additions
and
13 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: Build and deploy .NET Core application to Function App MigrationToolsTelemetery | ||
on: | ||
push: | ||
branches: | ||
- topic/niggles | ||
|
||
env: | ||
AZURE_FUNCTIONAPP_NAME: MigrationToolsTelemetery | ||
AZURE_FUNCTIONAPP_PACKAGE_PATH: src\MigrationTools.Telemetery\published | ||
CONFIGURATION: Release | ||
DOTNET_CORE_VERSION: 8.0.x | ||
WORKING_DIRECTORY: src\MigrationTools.Telemetery | ||
DOTNET_CORE_VERSION_INPROC: 6.0.x | ||
|
||
jobs: | ||
build: | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: ${{ env.DOTNET_CORE_VERSION }} | ||
- name: Setup .NET Core (for inproc extensions) | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: ${{ env.DOTNET_CORE_VERSION_INPROC }} | ||
- name: Restore | ||
run: dotnet restore "${{ env.WORKING_DIRECTORY }}" | ||
- name: Build | ||
run: dotnet build "${{ env.WORKING_DIRECTORY }}" --configuration ${{ env.CONFIGURATION }} --no-restore | ||
- name: Publish | ||
run: dotnet publish "${{ env.WORKING_DIRECTORY }}" --configuration ${{ env.CONFIGURATION }} --no-build --output "${{ env.AZURE_FUNCTIONAPP_PACKAGE_PATH }}" | ||
- name: Publish Artifacts | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: functionapp | ||
path: ${{ env.AZURE_FUNCTIONAPP_PACKAGE_PATH }} | ||
deploy: | ||
runs-on: windows-latest | ||
needs: build | ||
steps: | ||
- name: Download artifact from build job | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: functionapp | ||
path: ${{ env.AZURE_FUNCTIONAPP_PACKAGE_PATH }} | ||
- name: Deploy to Azure Function App | ||
uses: Azure/functions-action@v1 | ||
with: | ||
app-name: ${{ env.AZURE_FUNCTIONAPP_NAME }} | ||
publish-profile: ${{ secrets.MigrationToolsTelemetery_3736 }} | ||
package: ${{ env.AZURE_FUNCTIONAPP_PACKAGE_PATH }} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Function Build & Release (Azure DevOps Migration Tools) | ||
|
||
permissions: | ||
contents: read | ||
pull-requests: write | ||
|
||
on: | ||
push: | ||
branches: ["main"] | ||
tags-ignore: ["v*-*"] | ||
pull_request: | ||
branches: ["main"] | ||
workflow_dispatch: | ||
inputs: | ||
ForceRelease: | ||
description: 'Force a release! Use when changes hapen out of sync and `src` and `docs` folder changes are not detected.' | ||
required: false | ||
default: false | ||
type: boolean | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
defaults: | ||
run: | ||
shell: pwsh | ||
|
||
jobs: | ||
|
||
# Setup & Configuration |
This file contains 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.