Step 6 - dotnet publish - Build
  • 18 Nov 2019
  • 1 Minute to read
  • Contributors
  • Comment
  • Dark
    Light
  • PDF

Step 6 - dotnet publish - Build

  • Comment
  • Dark
    Light
  • PDF

Article Summary

In this task we will execute the publish command in .net core against the solution. In our case this will package up the Azure Function as a zip file that we can deploy.

A picture of this task is below:

image.png

YAML

The Yaml for this task is below:


variables:
  BuildConfiguration: 'Release'

steps:
- task: DotNetCoreCLI@2
  displayName: 'dotnet publish'
  inputs:
    command: publish
    publishWebProjects: false
    projects: '**/*.csproj'
    arguments: '-c $(BuildConfiguration) -o $(Build.StagingDirectory)/ci-Build --no-build'

Was this article helpful?