Manage Azure Artifacts N Package Manager

 

Devops > Artifacts (Last Link) > Click “Create a feed”

 

  • Choose Organization, - want to share feed with other project in same organization
  • Specific  People- if you want to share with specific people 

 

 

Select your feed

 

 

Package and push our existing packages on to above feed

DevOps > Create a new build pipeline

 

Created Pipeline will be some thing like 

  • Give Assembly Name
  • Remove 2 Assembly Task
  • Upgrade NuGet Package to 6.0.0

 

 

Task Changes

Task 1: download all NuGet 6.0

Task 2: Restore- This time restore and to push it to my own private feed.

  • Add a New Task of Nuget after Build Task - For Package
    • Package is basically it will look for my project file.

 

  • Clone newly added task - and let me do a push. After Packing we have to push
    • We are filtering .NuGet package files.
    •  
    • There is a ! sight, we are ignoring dot symbol package and the target feed is PracticeFeed01.

 

 

Give Permission - Handle if pushing failed due to access issue

  • Give necessary Permission or Role
  • Open Feed settings in Artifact window
    • Go to Permission Tab and check role
      • Edit permission for build service permission
      • Git role or Contributor at least, to push the feed
      • Click button Add user/groups
        • select your build service and select contributor and click save button
  • Update role will be like this

 

 

Go back to your Build Pipeline  > Pipeline  

Get Latest version at Pipeline Task

 

 

continue with Task 2: Restore- 

  •  Let save and Queue it 
  •  Save and Run
    •  

 

 

See the end result of pipeline

 

 

Verify Artifacts created

DevOps > Artifact 

 


Consume this Artifact

There are many methods to use it; 

  • Can download it (click on artifact link to see the default)
  • Can use this PowerShell command to execute on your Visual Studio and add this package into your application
  • Can connect to your feed using Visual Studio directly.
    • Connect to feed button above and choose visual studio
  • Use with in your pipeline
    • Go to your Build Pipeline > Edit it
      • Disable 2 task we already have Artifact now
      • Change Restore Task, open it in edit mode
        • Earlier we trying to restore from Nuget package repo for our feed, but this time we are using our feed for restore
          • Uncheck Use Package from NuGet.org
          • and choose artifact from drop down 
        • Now we have changed the location and we are trying to restore it from my own private feed that is from this location.

 

Save & Queue and then run this pipeline 

  • Successfully Run

 

  • Restore from new location now

 

So this is the private feed what we have created. So this is how you can consume the packages which you kept into your own private location.


Related Question