SSH Access to CCI
Two paths — password login (zero-config) and key-based passwordless (recommended for remote IDEs)
Prerequisites
- CCI instance in Running state
- Port 22 open (default)
- A local terminal (Mac/Linux Terminal, Windows PowerShell / Cmd)
Option 1 — SSH login (password)
Best for ad-hoc debugging, zero config.
- Open the CCI detail page, click "Access credentials" on the right
- Copy the SSH connection command and SSH password
- Paste in your local terminal, enter the password when prompted
$ ssh -p 32100 root@cci-xxx.alayanew.com
root@cci-xxx.alayanew.com's password: ********
Welcome to Alaya CCI...
root@xxx:~#Option 2 — Passwordless (recommended)
Best for VS Code Remote / JetBrains Gateway / long-running dev.
1. Generate a local SSH key
If you don't already have one:
ssh-keygen
# Press Enter through all prompts to write ~/.ssh/id_rsa and ~/.ssh/id_rsa.pub2. Copy the public key
| Platform | Public key path |
|---|---|
| Linux / Mac | ~/.ssh/id_rsa.pub |
| Windows | C:\Users\<user_name>\.ssh\id_rsa.pub |
cat ~/.ssh/id_rsa.pub
# Copy the entire string (ssh-rsa AAAA... to the end)3. Add the key in the console
Console → Account → SSH keys → Add key
| Field | Required |
|---|---|
| Key name | Yes |
| Description | No |
| Public key | Yes — paste from previous step |
When does it take effect?
After adding the key, you need to restart the container or create a new one for the key to load. Running instances don't pick it up dynamically.
4. Verify passwordless login
ssh -p 32100 root@cci-xxx.alayanew.com
# No password promptVS Code Remote one-liner
Add to ~/.ssh/config:
Host cci-train
HostName cci-xxx.alayanew.com
Port 32100
User root
IdentityFile ~/.ssh/id_rsaIn VS Code: Remote-SSH: Connect to Host → cci-train — local-feeling editing.
FAQ
Q: Why Permission denied (publickey)?
A: Check the public key was pasted in full, and that the container restarted after the key was added.
Q: Can I disable password login and accept only keys?
A: Inside the container edit /etc/ssh/sshd_config, set PasswordAuthentication no, then systemctl restart sshd.
Last updated on
