File tree Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -82,6 +82,9 @@ runner_org: no
8282# Name to assign to this runner in GitHub (System hostname as default)
8383runner_name : " {{ ansible_hostname }}"
8484
85+ # Labels to apply to the runner
86+ runner_labels : " ''"
87+
8588# Custom service name when usign Github Enterprise server
8689# service_name: actions.runner._services.{{ runner_name }}.service
8790
Original file line number Diff line number Diff line change @@ -35,6 +35,9 @@ runner_org: no
3535# Name to assign to this runner in GitHub (System hostname as default)
3636runner_name : " {{ ansible_hostname }}"
3737
38+ # Labels to apply to the runner
39+ runner_labels : " ''"
40+
3841# Custom service name when usign Github Enterprise server
3942# service_name: actions.runner._services.{{ runner_name }}.service
4043
Original file line number Diff line number Diff line change 8080
8181- name : Register runner (if new installation) for repo
8282 command : " {{ runner_dir }}/./config.sh --url {{ github_url }}/{{ github_owner | default(github_account) }}/{{ github_repo }} \
83- --token {{ registration.json.token }} --name {{ runner_name }} --unattended"
83+ --token {{ registration.json.token }} --name {{ runner_name }} --labels {{ runner_labels }} -- unattended"
8484 args :
8585 chdir : " {{ runner_dir }}"
8686 become : yes
9292
9393- name : Register runner (if new installation) for organization
9494 command : " {{ runner_dir }}/./config.sh --url {{ github_url }}/{{ github_owner | default(github_account) }} \
95- --token {{ registration.json.token }} --name {{ runner_name }} --unattended"
95+ --token {{ registration.json.token }} --name {{ runner_name }} --labels {{ runner_labels }} -- unattended"
9696 args :
9797 chdir : " {{ runner_dir }}"
9898 become : yes
104104
105105- name : Replace registered runner for repo
106106 command : " {{ runner_dir }}/config.sh --url {{ github_url }}/{{ github_owner | default(github_account) }}/{{ github_repo }} \
107- --token {{ registration.json.token }} --name {{ runner_name }} --unattended --replace"
107+ --token {{ registration.json.token }} --name {{ runner_name }} --labels {{ runner_labels }} -- unattended --replace"
108108 args :
109109 chdir : " {{ runner_dir }}"
110110 become : yes
116116
117117- name : Replace registered runner for organization
118118 command : " {{ runner_dir }}/config.sh --url {{ github_url }}/{{ github_owner | default(github_account) }} \
119- --token {{ registration.json.token }} --name {{ runner_name }} --unattended --replace"
119+ --token {{ registration.json.token }} --name {{ runner_name }} --labels {{ runner_labels }} -- unattended --replace"
120120 args :
121121 chdir : " {{ runner_dir }}"
122122 become : yes
You can’t perform that action at this time.
0 commit comments