Skip to content

Initial login to Claude Code is failing - cloudui is passing /exit command? #547

@oravecz

Description

@oravecz

Describe the bug
I attempt to "Connect my AI Agent" and the shell and the "Claude CLI Login" modal opens.

The process starts Claude Code and immediately exits.

Looking at the logs, I can see why

Initial command: claude /exit --dangerously-skip-permissions
Full CloudUI Logs

``` WebSocket connection attempt to: /shell?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjEsInVzZXJuYW1lIjoiamNvb2tAaGVscG1lYnJhbmRzLmNvbSIsImlhdCI6MTc3MzUxNjU3MiwiZXhwIjoxNzc0MTIxMzcyfQ.U06Byp8S61Xnv5aM3dwFrmlbWOXn01ODhbD1M5jqAc0 [OK] WebSocket authenticated for user: jcook@helpmebrands.com [INFO] Client connected to: /shell?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOjEsInVzZXJuYW1lIjoiamNvb2tAaGVscG1lYnJhbmRzLmNvbSIsImlhdCI6MTc3MzUxNjU3MiwiZXhwIjoxNzc0MTIxMzcyfQ.U06Byp8S61Xnv5aM3dwFrmlbWOXn01ODhbD1M5jqAc0 🐚 Shell client connected 📨 Shell message received: resize 📨 Shell message received: resize 📨 Shell message received: init [INFO] Starting shell in: /Users/jimcook/Projects/cloudcli 📋 Session info: Plain shell mode 🤖 Provider: plain-shell ⚡ Initial command: claude /exit --dangerously-skip-permissions 🔧 Executing shell command: claude /exit --dangerously-skip-permissions 📐 Using terminal dimensions: 110 x 35 🟢 Shell process started with PTY, PID: 41478 📨 Shell message received: input 📨 Shell message received: input 📨 Shell message received: input 📨 Shell message received: input 🔚 Shell process exited with code: 0 signal: 0 🔌 Shell client disconnected ```

Apparently, the shell is doing exactly what CloudUI is asking it do do. I cannot figure out why CloudUI is not passing claude /login

To Reproduce
I am running

  • Claude Code v2.1.74
  • CloudCLI v1.25.2
  • Running using npm install, cloudcli from a folder. No env variables.

Steps to reproduce the behavior:

  1. Go to http://localhost:3001
  2. Sign in, configure Git
  3. On "Connect Your AI Agents", select [Login] for Claude Code
  4. The Claude CLI Login appears, and immediately exits (see screenshot)

Looking at the logs, you can see that Claude Code was invoked with the /exit command causing it to immediately exit

Expected behavior
I expected Claude Code to be invoked with claude /login instead of claude /exit

Screenshots

Image

Additional Context
Running on MacOS Tahoe 26.3.1 (25D2128) with zsh shelll

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions