Skip to content

Ham market (#37)

Ham market (#37) #5

# Docs for the Azure Web Apps Deploy action: https://github.com/azure/functions-action
# More GitHub Actions for Azure: https://github.com/Azure/actions
name: af0e-functions - dev to dev
on:
push:
branches:
- dev
paths:
- 'src/AF0E.Functions/**'
workflow_dispatch:
env:
AZURE_FUNCTIONAPP_PACKAGE_PATH: 'src/AF0E.Functions' # set this to the path to your web app project, defaults to the repository root
DOTNET_VERSION: '8.x' # set this to the dotnet version to use
jobs:
build-and-deploy:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup .NET ${{env.DOTNET_VERSION}}
uses: actions/setup-dotnet@v1
with:
dotnet-version: ${{env.DOTNET_VERSION}}
- name: Build
shell: pwsh
run: |
pushd './${{env.AZURE_FUNCTIONAPP_PACKAGE_PATH}}'
dotnet build --configuration Release --output ./output
popd
- name: Deploy to Azure
uses: Azure/functions-action@v1
id: fa
with:
app-name: 'af0e-functions'
slot-name: 'dev'
package: '${{env.AZURE_FUNCTIONAPP_PACKAGE_PATH}}/output'
publish-profile: ${{secrets.DX_SCRAPER_FN_DEV_PUBLISH_PROFILE}}