Skip to content

Using Claude Code and Codex on Mobile With a Full VM

3 min readWorkspacesTutorial

Dinner has just arrived when a checkout alert lands. Your laptop is at home. Your repository, dependencies, and coding agent do not have to be.

With Layerbase AI VM Workspaces, your agent runs on an actual Linux computer. Your phone connects to its terminal through the browser. Claude Code or Codex can investigate the project, reproduce a failure, and prepare a patch using the tools and access you configured. You review the result and ship through your normal workflow.

This is a terminal in your pocket: the same CLI interface you use at your desk, connected to the VM's shell and filesystem. It feels familiar because it is the actual tool, rather than a separate chat interface that you must explain your project to again.

Set up on a computer first

First-time setup is easier on a computer because you are connecting GitHub and signing in to your agent accounts. Do that before you need the phone workflow:

  1. Create a workspace from AI VM Workspaces and wait for it to become ready.
  2. Connect the Layerbase GitHub App and choose the repositories this workspace can access.
  3. Install Claude Code or Codex from the agents panel, then follow its sign-in flow with your intended provider account.
  4. Open Terminal, create a named session, and start the agent in your project or a feature worktree.
  5. Try one small change and review the diff so you know the setup works.

The Claude Code setup guide and Codex setup guide cover account sign-in and API-key overrides. Your workspace pays for the VM; agent usage goes to your supported subscription or API account under that provider's limits.

Continue from your phone

Sign in to Layerbase on your phone, open AI VM Workspaces, and choose the machine you prepared. Open Terminal and use Sessions to select the existing named session. You are reconnecting to the process on the VM; this does not import a session that only existed on your laptop.

You can also add Layerbase to your phone's home screen as a progressive web app (PWA). There is no native Layerbase mobile app. The terminal requires an internet connection, and mobile usability will keep improving during beta. Extra terminal keys help with commands that a phone keyboard makes awkward; a larger screen is still useful for a long diff.

Closing the browser leaves the session on the running VM. An agent can still finish, fail, hit a limit, or wait for input. Stopping or rebooting the VM interrupts running processes.

A small outage task you can review

Give the agent a concrete starting point. For example:

text
In acme/api, investigate the checkout failure introduced by the last release.
Create a fix worktree, reproduce the failure, and add a regression test.
Prepare the smallest fix and show me the diff and test results.
Do not deploy or change production data.

Read the findings, inspect the patch, and use your usual review and deployment process. If resolving the critical outage requires logs or remote access, configure the appropriate tools and permissions in advance. A VM does not automatically gain access to production.

The same workflow fits a quick feature: describe the change on your phone, let the agent implement it on a branch, and review it when you have a moment.

Bring the agent you already use

Claude Code and Codex are two options. You can also use Cursor CLI, Devin CLI, Gemini CLI, Grok Build, or another compatible Linux command-line tool. The dashboard has installers for supported agents; ordinary shell access lets you install other compatible tools yourself. For naming clarity, Devin Desktop is the editor formerly called Windsurf; this workflow uses Devin's CLI.

No agent subscription? Install OpenCode and choose an available free model. OpenCode documents its current free models; availability and usage limits can change. The VM subscription is still separate.

Keep work and personal accounts apart

If you juggle work and personal subscriptions, use separate VMs: work repositories and work agent credentials on one, personal projects and personal accounts on the other. Name them clearly before you connect from your phone. Tabs on one VM share its user environment and are not separate credential stores.

You keep the familiar terminal workflow and get another way to reach it. Choose a workspace, complete setup at your computer, and bring your agents out with you.