I created a Windows runner with the default labels:
- self.hosted
- windows
And added the following pipeline to the repo:
pipelines:
tags:
AssetReadingExportService-*:
- step:
name: Build the service
runs-on:
- 'windows'
script:
- dotnet build "AssetReadingExportService.csproj" -c Release -o "build/AssetReadingExportService"
I ran my pipeline, which failed because I'm targeting .net 6.0 so I needed msbuild17. I installed VS2022, and decided that I would add labels to indicate what tools are available on the runner. I've updated my runner to have the following labels:
- msbuild16
- msbuild17
- azurecli
- self.hosted
- windows
I updated the pipeline to require the specific msbuild version:
pipelines:
tags:
AssetReadingExportService-*:
- step:
name: Build the service
runs-on:
- 'msbuild17'
script:
- dotnet build "AssetReadingExportService.csproj" -c Release -o "build/AssetReadingExportService"
Now the build always fails and says no matching runner could be found.
Possibilities that I have ruled out:
What am I missing here?
Note: I'm using a Windows runner because this is a mono-repo, and some of the services require a Windows environment to build
Hi @and
For windows runners, at a minimum you will need the windows label, in addition to any further custom labels. Please see Using your Windows runner in your build configuration at https://support.atlassian.com/bitbucket-cloud/docs/configure-your-runner-in-bitbucket-pipelines-yml/ for more information.
That was the issue, thanks Graham. Is there a way to add the 'windows' label to the whole pipeline, or do I need to specify it on each step?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We haven't provide global option for `runs-on` at the moment, so unfortunately you have to specify it on each step
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.