FROM node:22.17.0-bookworm-slim@sha256:b04ce4ae4e95b522112c2e5c52f781471a5cbc3b594527bcddedee9bc48c03a0

ARG CLAUDE_CODE_VERSION=2.1.207

RUN apt-get update \
    && apt-get install -y --no-install-recommends \
        ca-certificates \
        curl \
        git \
        procps \
        python3 \
        python3-pip \
    && npm install --global "@anthropic-ai/claude-code@${CLAUDE_CODE_VERSION}" \
    && python3 -m pip install --break-system-packages --no-cache-dir \
        jsonschema \
        pytest \
        pyyaml \
        ruff==0.15.1 \
    && apt-get clean \
    && rm -rf /var/lib/apt/lists/* /root/.cache

WORKDIR /workspace

USER 65532:65532

ENTRYPOINT []
