Two Codex tasks in the same checkout fight over files, ports and the meaning of a failing test. The straightforward fix is a machine per task. A Sandscale workspace is a persistent cloud computer with its own disk, so the clone, the tools and Codex's sign-in stay with that task. This is the short path to that setup. The longer non-interactive walkthrough is codex exec in a cloud workspace. If you would rather keep Codex on the laptop and send only some commands away, that is the MCP setup.
Start with an account
Sign up for Sandscale. The Quickstart says you start on the Free plan: 100 awake vCPU-hours a month, 3 boxes at once, and up to 2 vCPU per box. The workspaces docs say Free includes one workspace. That is enough to try one task on one machine. When you want a machine per task at the same time, a paid plan includes more. Pro and up need a payment method; Free does not.
A running workspace counts toward the plan's hours whether Codex is busy or waiting. Paused time does not count, per the pricing page.
Create a workspace for the task
curl -fsSL https://sandscale.dev/install | sh
sandscale login
sandscale workspace templates-list
sandscale workspace create --name codex-pay-1423 --template-id TEMPLATE_ID --ttl-seconds 28800
sandscale workspace ssh codex-pay-1423
Name the workspace after the task or ticket. Inside the machine, install Codex the way OpenAI's docs describe, sign in, and clone only that task's branch. The disk persists, so you do this once per workspace.
Codex needs to reach OpenAI's API. Network access follows your plan and your organization's policy.
Run the task, then stop
Work on the workspace, or drive codex exec there as the longer post describes. When the pull request is opened, or the task is otherwise done, stop the machine:
sandscale workspace stop --ws-id WORKSPACE_ID
The disk is kept, so you can come back to the same branch and caches. When the work is really finished, sandscale workspace delete --ws-id WORKSPACE_ID removes the workspace and its disk, and asks before it runs.
If a second task should not see the first task's files, do not reuse the same workspace. Sign up if you still need an account, create a workspace per task, and stop each one when its work ends.
Originally published on the Sandscale blog.
Top comments (0)