Ready to go docker image with Azure Devops agent with some tools to run pipelines included.
Explore the docs »
Report Bug
·
Request Feature
Table of Contents
This project is the finished work of creating and Azure DevOps Agent container image, with some components to run pipelines. I just followed Microsoft documentation, and installed the tools required for me. Check the Microsoft doc for more info: https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/docker?view=azure-devops
You can execute current release with Docker.
docker run -e AZP_URL="https://dev.azure.com/[yourorganization]" -e AZP_TOKEN=[token] --name AzureDevOpsAgent --detach ghcr.io/ark667/azuredevopsagent:master
You can also clone the repo and build the image yourself.
git clone https://github.com/Ark667/AzureDevOpsAgent.git
Docker build -t azuredevopsagent .\AzureDevOpsAgent
Build image.
docker build -f .\Amd64\Dockerfile -t azure-devops-agent .
Check creted image.
docker images --filter "reference=azure*"
Basic usage is pretty straightforrward, just run the container with your organization name and access token. It will connect automatically and become available in Azure Devops portal to process pipielines.
docker run -e AZP_URL="https://dev.azure.com/[yourorganization]" -e AZP_TOKEN=[token] -e AZP_AGENT_NAME=AzureDevOpsAgent --name AzureDevOpsAgent --detach azuredevopsagent:master
Setting this volume, it will be able to execute docker builds using the host machine docker service.
docker run -e AZP_URL="https://dev.azure.com/[yourorganization]" -e AZP_TOKEN=[token] -e AZP_AGENT_NAME=AzureDevOpsAgent --name AzureDevOpsAgent -v /var/run/docker.sock:/var/run/docker.sock --detach azuredevopsagent:master
The image is built for Amd64 and Arm64. Docker will pull the matching architecture on the host, but you can take it explicitly.
docker run --restart="always" --platform arm64 -e AZP_URL="https://dev.azure.com/[yourorganization]" -e AZP_TOKEN=[token] -e AZP_AGENT_NAME=AzureDevOpsAgent -e AZP_POOL=Mac --name AzureDevOpsAgent -v /var/run/docker.sock:/var/run/docker.sock --detach ghcr.io/ark667/azuredevopsagent:master
Be sure that start.sh script has LF line endings.
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Feel free to use the code in this repository as it is under MIT license. See LICENSE.txt
for more information. You can also buy me a coffee for my little effort.
Aingeru Medrano - @AingeruBlack
Project Link: https://github.com/Ark667/AzureDevOpsAgent