Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Choosing between workspace level pipeline runners

In our org initially we only had repository level pipeline runners
As the number of projects grew we found most of the runners can be streamlined to a few rather managing multiple individual runners, otherwise costing CPU, Memory and Maintenance.

We decided to create workspace level runner that can be shared across multiple repos

We don't know how to choose/define which workspace runner to use within individual repository.

Any examples/help/references will be greatly appreciated

Note: We use self.hosted windows pipelines

 

1 answer

1 accepted

0 votes
Answer accepted
Patrik S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Oct 12, 2023 • edited

Hello @sreeram_anikodemahadevan and thank you for reaching out to the Community!

When a pipeline build is triggered, it will be assigned to the first available runner that matches all the labels you have configured in the pipeline step.

So if you want to divide your runner(s) into groups, you can assign different labels to each set of runners, and then on each repository configure the pipeline steps to use the desired runner/group of runners.

Runner labels can be assigned during the runner creation, and for already created runners you can edit the label by accessing the runner's settings. For workspace runners, you can edit the labels as below: 

  1. Navigate to Workspace Settings > Workspace Runners. This will show a list of all the runners created under that workspace
  2. On the line containing the runner you want to edit the label, select the three-dot icon in the column Actions
  3. In the drop-down, click on Edit option
  4. Assign any new labels you want. You can repeat the same label in multiple runners if you want to create groups of runners. Some labels are required and can't be removed, such as self.hosted and windows (for windows runners) : 
    Screenshot 2023-10-12 at 4.14.55 PM.png

In the example above we are assigning the label group1 to one of the runners. Suppose we have another runner assigned with the group2 label. You can define in each repository's pipelines YML file which step will run in which runner/group of runners as the following example : 

pipelines:
  default:
      - step:
          name: Step 1
          runs-on:
            - 'windows'
            - 'self.hosted'
            - 'group1'
          script:
            - echo "This step will run on a runner of group1";
      - step:
          name: Step 2
          runs-on:
            - 'windows'
            - 'self.hosted'
            - 'group2'
          script:
            - echo "This step will run on a runner of group2";

where step 1 will be executed in any runner of group1, while step 2 will be assigned to a runner in group2.

Hope that helps to clarify your questions! Should you have any follow-up questions, let me know :)

Thank you, @sreeram_anikodemahadevan !

Patrik S

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events