
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
docker-cursor-agent
Advanced tools
A Docker wrapper for Cursor CLI that allows you to run cursor-agent commands inside a container.
This project provides a Docker container that wraps the Cursor CLI, allowing you to execute cursor-agent commands as if it were a native binary. The container acts as a transparent wrapper, passing all arguments through to the cursor-agent binary.
gh CLI installed and authenticated (required for local deployment)CURSOR_API_KEY environment variable set (required for testing)# Using npm script
bun run build
# Or directly with Docker
docker build -t docker-cursor-agent .
The image is based on debian:stable-slim and optimized for size (~291MB).
docker pull ghcr.io/circlesac/docker-cursor-agent:latest
This package includes a CLI tool to generate cursor-agent MCP configuration files from an mcp.json file.
# Install globally
npm install -g docker-cursor-agent
# Or use with npx (no installation needed)
npx docker-cursor-agent --file <mcp.json> --out <output-dir>
# Generate MCP config from mcp.json
npx docker-cursor-agent --file ./mcp.json --out ./build
# This creates:
# ./build/.cursor/mcp.json
# ./build/.cursor/projects/workspace/mcp-approvals.json
--file, -f - Path to input mcp.json file (required)--out, -o - Output directory where .cursor folder will be created (required, defaults to current directory)After generating the config files, use them with the Docker container:
docker run --rm \
-e CURSOR_API_KEY=your_key \
-v $(pwd)/build/.cursor:/root/.cursor \
ghcr.io/circlesac/docker-cursor-agent:latest \
--print --output-format stream-json "your prompt"
Run cursor-agent commands through Docker:
# Using the published image from GHCR
docker run --rm -e CURSOR_API_KEY=your_key ghcr.io/circlesac/docker-cursor-agent:latest --version
docker run --rm -e CURSOR_API_KEY=your_key ghcr.io/circlesac/docker-cursor-agent:latest --help
# Or using locally built image
docker run --rm -e CURSOR_API_KEY=your_key docker-cursor-agent --version
All arguments are passed through to cursor-agent:
# Using published image
docker run --rm -e CURSOR_API_KEY=your_key ghcr.io/circlesac/docker-cursor-agent:latest <your-args>
# Or using locally built image
docker run --rm -e CURSOR_API_KEY=your_key docker-cursor-agent <your-args>
CURSOR_API_KEY - Required for cursor-agent to function (pass via -e flag)bun install
# Build TypeScript source code
bun run build
# Build Docker image
bun run build:docker
The build script compiles TypeScript source to JavaScript in the dist/ directory. The build:docker script builds the Docker image locally.
bun run test
Note: Tests require CURSOR_API_KEY to be set in your environment. Tests will fail if it's not present.
bun run lint
Deploy the Docker image to GitHub Container Registry:
# Deploy using TypeScript script (recommended for production)
bun run deploy
# Or test deployment locally using act (requires act installed)
bun run deploy:act
The deploy script will:
GITHUB_TOKEN, GHCR_TOKEN, or gh CLI)ghcr.io/circlesac/docker-cursor-agent:latestPublished Image: The image is available at ghcr.io/circlesac/docker-cursor-agent:latest
Note: deploy:act uses act to test the GitHub Actions workflow locally. It passes GITHUB_TOKEN directly to act using gh auth token.
GITHUB_TOKEN - Auto-provided in GitHub Actions (has GHCR permissions)GHCR_TOKEN - Optional override for local deploymentGHCR_TAG - Optional image tag (defaults to latest)GITHUB_ACTOR - Optional username for login (defaults to repo owner)For local deployment, ensure you have gh CLI authenticated:
gh auth login --scopes write:packages
Or set GHCR_TOKEN environment variable:
export GHCR_TOKEN=your_token
bun run deploy
docker-cursor-agent/
├── .dockerignore # Docker ignore patterns
├── .github/
│ └── workflows/
│ └── deploy.yml # GitHub Actions workflow for automated deployment
├── .gitignore # Git ignore patterns
├── Dockerfile # Debian-based container definition
├── package.json # Bun project configuration
├── README.md # This file
├── src/
│ ├── cli.ts # CLI entry point
│ └── utils.ts # MCP config processing utilities
├── scripts/
│ └── deploy.ts # Deployment script to GHCR
├── tests/
│ ├── cli.test.ts # CLI tests
│ └── docker.test.ts # Docker tests
├── tsconfig.json # TypeScript configuration (base)
├── tsconfig.build.json # TypeScript build configuration
└── vitest.config.ts # Vitest configuration
FAQs
Docker wrapper for Cursor CLI
We found that docker-cursor-agent demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.