Azure Devops

NuKeeper supports Azure Devops, VSTS and TFS on premise. The same instruction apply for all these platforms!

NuKeeper supports integration with Azure Devops in two ways. One of them is to use the repo command and the other one is through the extension. The benefit of the extension is that you can make a build pipeline with the extension and schedule your pipeline. This way you can automate your updating flow.

Extension

The NuKeeper extension is available in the marketplace. In order to install it you need to add it to your organisation click the Get it free button and follow the installation. Once that is done you can create a new pipeline and use the extension.

Installation

Azure Devops gives us the option to do it either in editor mode, or in yaml.

Yaml

  1. Add a new build pipeline and select yaml.
  2. Add the following yml file and adjust where necessary:

        resources:
           - repo: self #point to its own repo, change it if you don't want that
        pool:
            name: Hosted VS2017 # can be anything you want
        steps:
          - task: nukeeper.nukeeper.nukeeper.NuKeeper@0
            displayName: NuKeeper
    
  3. Optionally add extra arguments, The extension just call the repo command, so any arguments extra for your repo command can be added here.

    resources:
        steps:
        - task: nukeeper.nukeeper.nukeeper.NuKeeper@0
        displayName: NuKeeper
        inputs:
            arguments: ‘-m 3 -v d’
    

  4. Go to triggers and click the Add button to add your schedule. This cannot be done in yml yet.

  5. Finally give the build service user the required Permissions and take it for a spin by qeueing a new build!

Editor mode

  1. Create a new build pipeline for editor mode.
  2. Select your repository and select the master branch.
  3. Add a new task to your pipeline and select NuKeeper.
  4. Optionally, click on the task and add additional arguments to the Arguments field. For help on the arguments checkout the Configuration page. The extension just call the repo command, so any arguments extra for your repo command can be added here.
  5. Go to triggers and click the Add button to add your schedule.
  6. Enable your agent to access the oauth token: Oauth checkmark

  7. Finally give the build service user the required Permissions and take it for a spin by qeueing a new build!

Permissions

The extensions uses the build service user to make a PR. By default this user is not allowed to do that. We have to give it the permissions to do so:

  1. Go to “Project settings” in your AzureDevops home screen.
  2. Click repositories
  3. Click Git repositories
  4. Click the build service User(the bottom one, something like: Project collection build service)

Give it the following rights:

  • Contribute Allow
  • Contribute to pull requests Allow
  • Create branch Allow

Repo command

The repo command works for azure-devops & vsts they same as for the other platforms. You will need a personal access token to use the repo command.

nukeeper repo "https://dev.azure.com/{org}/{project}/_git/{repo}/" <PAT>

Additional arguments

Add any additional arguments that are available for the repo command

nukeeper repo "https://dev.azure.com/{org}/{project}/_git/{repo}/" <PAT> -m 10

The -m 10 tells NuKeeper that it may update 10 packages. For more parameters checkout the Configuration page.