Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .cursor/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
FROM node:24-bookworm-slim

ARG PNPM_VERSION=10.32.1
ENV COREPACK_ENABLE_DOWNLOAD_PROMPT=0

RUN apt-get update \
&& apt-get install -y --no-install-recommends git sudo \
&& rm -rf /var/lib/apt/lists/*

RUN id -u ubuntu >/dev/null 2>&1 || useradd -m -s /bin/bash ubuntu \
&& usermod -aG sudo ubuntu \
&& echo "ubuntu ALL=(ALL) NOPASSWD:ALL" >/etc/sudoers.d/ubuntu \
&& chmod 0440 /etc/sudoers.d/ubuntu

RUN corepack enable && corepack prepare "pnpm@${PNPM_VERSION}" --activate

WORKDIR /workspace

COPY package.json pnpm-lock.yaml pnpm-workspace.yaml ./
COPY packages/cddl/package.json packages/cddl/package.json
COPY packages/cddl2ts/package.json packages/cddl2ts/package.json
COPY packages/cddl2java/package.json packages/cddl2java/package.json
COPY packages/cddl2py/package.json packages/cddl2py/package.json

RUN pnpm install --frozen-lockfile

RUN chown -R ubuntu:ubuntu /workspace

USER ubuntu
8 changes: 8 additions & 0 deletions .cursor/environment.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"name": "node-24-pnpm-workspace",
"user": "ubuntu",
"build": {
"dockerfile": "Dockerfile",
"context": ".."
}
}
9 changes: 9 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Cursor Cloud specific instructions

- This repository defines a repo-level cloud agent environment in `.cursor/environment.json`.
- The corresponding `.cursor/Dockerfile` pins Node 24 and pnpm 10.32.1, then preinstalls the pnpm workspace dependencies into `/workspace`.
- You can run these commands immediately in a fresh cloud agent without a preliminary `pnpm install`:
- `pnpm compile`
- `pnpm run test:typechecks`
- For focused Vitest runs, disable coverage so single-file or narrow test selections are not blocked by the repo's global coverage thresholds:
- `pnpm exec vitest --config vitest.config.ts --run --coverage.enabled=false packages/cddl/tests/parser.test.ts`