GitHub Self-Hosted Runner Packages and tools #128551
Replies: 3 comments 1 reply
-
GitHub-hosted runners come with preinstalled software. For self-hosted runners you need to install all software, tools and packages yourself (unless it's already included with OS/image you're using). Good practice is to include install/update steps in workflow, then you can be sure your workflow is runner-agnostic. |
Beta Was this translation helpful? Give feedback.
-
🕒 Discussion Activity Reminder 🕒 This Discussion has been labeled as dormant by an automated system for having no activity in the last 60 days. Please consider one the following actions: 1️⃣ Close as Out of Date: If the topic is no longer relevant, close the Discussion as 2️⃣ Provide More Information: Share additional details or context — or let the community know if you've found a solution on your own. 3️⃣ Mark a Reply as Answer: If your question has been answered by a reply, mark the most helpful reply as the solution. Note: This dormant notification will only apply to Discussions with the Thank you for helping bring this Discussion to a resolution! 💬 |
Beta Was this translation helpful? Give feedback.
-
🕒 Discussion Activity Reminder 🕒 This Discussion has been labeled as dormant by an automated system for having no activity in the last 60 days. Please consider one the following actions: 1️⃣ Close as Out of Date: If the topic is no longer relevant, close the Discussion as 2️⃣ Provide More Information: Share additional details or context — or let the community know if you've found a solution on your own. 3️⃣ Mark a Reply as Answer: If your question has been answered by a reply, mark the most helpful reply as the solution. Note: This dormant notification will only apply to Discussions with the Thank you for helping bring this Discussion to a resolution! 💬 |
Beta Was this translation helpful? Give feedback.
-
Github Self Hosted Runner
Do we need to install each packages and tools we use in the github action manually inside the selfhosted VM. Or will it comes automatically while we configure the github runner?
Body
I have a GitHub workflow to build java application and build a docker image and push to Azure Container Registry. In the GitHub hosted runner the workflow is running fine.
I need to work the same in a Self Hosted runner. So I have created a VM in Azure and configured the Github runner and updated the workflow to run-on to selfhosted runner.
name: Azure CLI script
uses: azure/cli@v2
with:
azcliversion: latest
inlineScript: |
az account show
name: Login to ACR
uses: docker/login-action@v3
with:
registry: ${{ secrets.xxxxxxxxx }}
username: ${{ secrets.xxxxxxxxx }}
password: ${{ secrets.xxxxxxxxx }}
name: Use Java 19
uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: '19'
These are the examples of some github actions I use, this is working fine on the github runner. But when I change to GitHub runner to self hosted runner its showing errors
Error: Unable to locate executable file: az. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable.
Error: Unable to locate executable file: docker. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable.
When I login in to the VM and installed the azure cli manually the first error was gone.
So my question is do we need to install each packages and tools we use in the github action manually inside the selfhosted VM. Or will it comes automatically while we configure the github runner?
Beta Was this translation helpful? Give feedback.
All reactions