From 02c74a21be17d5afbb9047011e8b0076ab3ba69d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Borja=20Dom=C3=ADnguez=20V=C3=A1zquez?= Date: Wed, 13 Aug 2025 12:42:18 +0200 Subject: [PATCH] add Ubuntu 24.04 Dockerfile example --- docs/pipelines/agents/docker.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/docs/pipelines/agents/docker.md b/docs/pipelines/agents/docker.md index 59c67b4ee22..a3ce0938ba7 100644 --- a/docs/pipelines/agents/docker.md +++ b/docs/pipelines/agents/docker.md @@ -241,6 +241,35 @@ Next, create the Dockerfile. ENTRYPOINT [ "./start.sh" ] ``` + * For Ubuntu 24.04: + ```dockerfile + FROM ubuntu:24.04 + ENV TARGETARCH="linux-x64" + # Also can be "linux-arm", "linux-arm64". + + RUN apt update && \ + apt upgrade -y && \ + apt install -y curl git jq libicu74 + + # Install Azure CLI + RUN curl -sL https://aka.ms/InstallAzureCLIDeb | bash + + WORKDIR /azp/ + + COPY ./start.sh ./ + RUN chmod +x ./start.sh + + # Create agent user and set up home directory + RUN useradd -m -d /home/agent agent + RUN chown -R agent:agent /azp /home/agent + + USER agent + # Another option is to run the agent as root. + # ENV AGENT_ALLOW_RUNASROOT="true" + + ENTRYPOINT [ "./start.sh" ] + ``` + * For Ubuntu 22.04: ```dockerfile FROM ubuntu:22.04