FROM docker.io/datadog/agent:7.80.3-jmx

ARG DATADOG_AGENT_VERSION=7.80.3
LABEL dd.agent.version=${DATADOG_AGENT_VERSION}

RUN apt-get -y update \
  && apt-get -y upgrade \
  && apt-get -y clean \
  && rm -rf /var/lib/apt/lists/*

RUN pip3 install cryptography==46.0.7

COPY --chown=dd-agent config.py entrypoint.sh ./
COPY --chown=dd-agent configs/ ./configs/
RUN  chmod +x ./entrypoint.sh
RUN  pip3 --version
RUN  pip3 install Jinja2==3.1.6

ENTRYPOINT ["./entrypoint.sh"]
