Kevin
Kevin

Reputation: 9389

Configure VSTS local build agent for deploys

I have a local VM that has successfully been running builds from VSTS.

After the builds are completed I have a deployment job that pushes my artifacts to a number of servers. This has been working fine for the past few months.

This morning, I received a message that I was out of "deployment minutes" and my deployments failed, however my builds completed.

Obviously it was building locally, but deploying in the cloud.

Is there a way I can configure my agent or my deployment job within VSTS to use my local agent?

Upvotes: 0

Views: 1310

Answers (3)

Kevin
Kevin

Reputation: 9389

Here is where I finally found the option to specify which agent the release should run on:

Run-on-agent option

Upvotes: 0

Thowk
Thowk

Reputation: 407

You should be able to add your agent to the pool (it requires some software installed there of course) and then select it instead of a hosted environment in the deployment step configuration:

Agent pools

At the bottom you can find:

The hosted pool provides all VSTS accounts with a single hosted build agent and a limited number of free build minutes each month. If you need more hosted build resources, or need to run more than one build concurrently, then you can either: - Deploy your own on-premises build agents - Buy additional hosted pipelines

Upvotes: 0

Daniel Mann
Daniel Mann

Reputation: 58981

You should just be able to switch your release definition to use the same agent queue as your builds. In each environment, click on each phase and change the agent queue it uses from "Hosted" to whatever you named your local agent queue.

You may need to install additional software (Azure PowerShell, if you're deploying to Azure, for example), but it will work the same -- the build and release agents are exactly the same software and use exactly the same tasks.

Upvotes: 1

Related Questions