0
votes

I am using deployment group to deploy a .NET Core Console app to an on prem VM. In order to register the target I run the PAT on the VM. Is there a way I can use a Service Account to generate the PAT and use that to register the VM instead of my personal account?

I have used this article as a guide. https://medium.com/@samjwright/automating-deployments-to-on-premis-servers-with-azure-devops-bb0e6cac4656

1
Not get your latest information, is the answer helpful for you? Or if you have any concern, feel free to share it here. - Hugh Lin

1 Answers

0
votes

Is there a way I can use a Service Account to generate the PAT and use that to register the VM instead of my personal account?

If you can use the service account to log in, then you can also create PAT with proper scopes in the user settings of the service account. You can refer to this ticket.

In addition, PAT is only used during registration of agent. The identity of agent pool administrator is needed ONLY at the time of registration and is not persisted on the agent, nor is used in any further communication between the agent and Azure Pipelines or TFS. Once the registration is complete, the agent downloads a listener OAuth token and uses it to listen to the job queue.