.Net Core app Versioning

Santhi Dhanuskodi 325 Reputation points
2024-08-05T15:14:32.53+00:00

Hi,

I have a .net core application which is containerized and deployed in AKS.

I would like to version the application, so that the version can be picked up by Azure devops build pipeline(YAML file), What is the right place to put the version, so that build yaml file can read it from?

Developer technologies ASP.NET ASP.NET Core
Community Center Not monitored
{count} votes

1 answer

Sort by: Most helpful
  1. Bruce (SqlWork.com) 77,686 Reputation points Volunteer Moderator
    2024-08-05T21:04:55.2466667+00:00

    see docs for build number:

    https://learn.microsoft.com/en-us/azure/devops/pipelines/process/run-number?view=azure-devops

    note: use the build number values to environment variable(s) supplied to the build by DevOps to add the build number to code. if you manually want to control the build number rather than DevOps, just define the env variable statically.

    .net core by default allow setting the assemble info from build:

    https://learn.microsoft.com/en-us/dotnet/standard/assembly/set-attributes-project-file

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.