This repository has been archived by the owner on May 29, 2023. It is now read-only.
chore(deps): update dependency microsoft.net.test.sdk to v17.6.0 #293
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
name: Build and Deploy | |
env: | |
OUTPUT_PATH: ${{ github.workspace }}/.output | |
on: | |
push: | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- name: 'Checkout' | |
uses: actions/checkout@755da8c3cf115ac066823e79a1e1788f8940201b # v3 | |
- name: Test functions | |
run: dotnet test --configuration Release src/Hashflags.Tests | |
- name: Publish functions | |
run: dotnet publish --configuration Release --output ${{ env.OUTPUT_PATH }} src/Hashflags | |
- name: Package functions | |
uses: actions/upload-artifact@83fd05a356d7e2593de66fc9913b3002723633cb # tag=v3 | |
with: | |
name: functions | |
path: ${{ env.OUTPUT_PATH }} | |
deploy: | |
runs-on: windows-latest | |
needs: build | |
if: github.ref == 'refs/heads/main' | |
env: | |
FUNC_APP_NAME: hashflags | |
steps: | |
- name: Download website | |
uses: actions/download-artifact@9782bd6a9848b53b110e712e20e42d89988822b7 # tag=v3 | |
with: | |
name: functions | |
path: ${{ env.OUTPUT_PATH }} | |
- name: 'Login via Azure CLI' | |
uses: azure/login@92a5484dfaf04ca78a94597f4f19fea633851fa2 # tag=v1 | |
with: | |
creds: ${{ secrets.AZURE_CREDENTIALS }} | |
- name: 'Run Azure Functions Action' | |
uses: Azure/functions-action@f438ecccd1b168da358efe9a8b732da92b28dba5 # tag=v1 | |
with: | |
app-name: ${{ env.FUNC_APP_NAME }} | |
package: ${{ env.OUTPUT_PATH }} |