This repository contains the scripts to create a Docker image that can act as an Azure DevOps agent.
It also contains scripts to create an Azure Container Instance environment & Azure Container Registry.
The Azure Function project acts as an orchestrator to start and stop the ACI based on the information it can retrieve from Azure DevOps.
Request:
{{baseUrl}}/build/builds?statusFilter=notStarted&api-version=6.0
Response:
{
"count": 0,
"value": []
}
{
"environments": [
{
"id": 70,
"deploySteps": [
{
// https://docs.microsoft.com/en-us/rest/api/azure/devops/release/releases/list?view=azure-devops-rest-6.0#deploymentoperationstatus
"status": "succeeded", // "queued", "queuedForAgent", "queuedForPipeline"
"hasStarted": true,
}
]
}
Opened
Scaling isn't possible in ACI.
Tom Kerkhove has an interesting post on this: https://blog.tomkerkhove.be/2021/01/02/autoscaling-azure-container-instances-with-azure-serverless/
Related blogposts of myself: