huserben / TfsExtensions

Extensions for TFS 2015+ such as custom Widgets (require TFS 2017) and Build Tasks
MIT License
44 stars 22 forks source link

Designate the resource to use in the pipeline #219

Closed bw5io closed 2 years ago

bw5io commented 2 years ago

Hi,

Thank you for your extension. This really helped us a lot! I was wondering if the extension can designate the resource to use during the pipeline. Is there a way to do that for now?

huserben commented 2 years ago

Hi @bw5io

could you elaborate what exactly you mean by "deisgnate the resource to use"? Is it about which specific agent is running the triggered pipeline?

bw5io commented 2 years ago

Hi @huserben ,

Thanks for the swift reply. No it's not.

In the YAML Pipeline there's a portion called resource which could be used to specify a pipeline or commit or stuff to get artifact / commit / version throughout the pipeline. We use resource because it would be easier for devs to choose the build run which includes the artifact they want in the azure devops interface. However we're also calling the same pipeline from other pipelines. Currently I don't know if I can specify resource using the plugin. I'm curious if there's a way to do that.

huserben commented 2 years ago

Ok, now I got it. I've never used the resources so far so I'm certainly no expert in this.

Also the task is at least currently not supporting this. As I've stopped most development activities I do also not have planned to introduce something like this in the near future (things might change, but that's the statement I could make today).

When it comes to whether it's possible, I believe so - almost anything can be set via the REST API :-)

If you are using YAML pipelines you could also check out the built-in functionality: Pipeline Triggers

Maybe this helps solving your problem. Back when this task was written YAML pipelines and pipeline triggers were not yet existing :-)

bw5io commented 2 years ago

I see. Thanks!