2025-06-14 00:43:00
github.com
Chat with AI over SSH.
English | 简体中文
# Replace username with your GitHub username
ssh username@chat.aigc.ing
crt-chat.mp4
We recommend using V.PS servers for Docker deployment.
- Copy the contents of
.env.example
to a.env
file and modify it according to the.env
file description below. - Create a
docker-compose.yml
file with the following content. This is all you need to deploy SSH AI Chat. If you need to deploy PostgreSQL and Redis alongside it, refer to the docker-compose.dev.yml file.
services:
ssh-ai-chat:
image: ghcr.io/ccbikai/ssh-ai-chat
ports:
- 22:2222
volumes:
- ./data:/app/data
env_file:
- .env
mem_limit: 4g
- Start with the
docker compose up -d
command. - Access using
ssh username@host -p 22
, making sure to replace the hostname and port number.
# Server name, optional, can be changed to your own domain
SERVER_NAME=chat.aigc.ing
# Whether it's a public server, required. If not configured, it defaults to private server and requires whitelist configuration
PUBLIC_SERVER=false
# Rate limiting settings, optional. TTL suffix is for time, LIMIT is for count. Strongly recommended for public servers
RATE_LIMIT_TTL=3600
RATE_LIMIT_LIMIT=300
LOGIN_FAILED_TTL=600
LOGIN_FAILED_LIMIT=10
# Blacklist and whitelist, optional. Configure GitHub usernames separated by commas
BLACK_LIST=alice
WHITE_LIST=bob
# Redis URL, optional. If not configured, it will use simulated Redis and data will be lost on restart
REDIS_URL=redis://default:ssh-ai-chat-pwd@127.0.0.1:6379
# Database URL, optional. If not configured, it will use PGLite to store data in the /app/data directory
DATABASE_URL=postgres://postgres:ssh-ai-chat-pwd@127.0.0.1:5432/ssh-ai-chat
# Umami configuration, optional
UMAMI_HOST=https://eu.umami.is
UMAMI_SITE_ID=6bc6dd79-4672-44bc-91ea-938a6acb63a2
# System prompt, optional
AI_MODEL_SYSTEM_PROMPT="You are an AI chat assistant that..."
# Model list, **required**, separated by commas
AI_MODELS="DeepSeek-V3,DeepSeek-R1,Gemini-2.5-Flash,Gemini-2.5-Pro"
# Models that support chain of thought, use `` tags to return reasoning chain. Optional, if not configured will display reasoning content
AI_MODEL_REASONING_MODELS="DeepSeek-R1,Qwen3-8B"
# System reasoning model, optional, used for generating conversation titles. Only one model can be configured. If not configured, uses the first model from the model list
AI_SYSTEM_MODEL="Qwen3-8B"
# Model configuration file, configures API call information for models in `AI_MODELS` and `AI_SYSTEM_MODEL` lists.
# Name format: prefix `AI_MODEL_CONFIG_`, model name in all caps, `-` and `.` replaced with `_`. Conversion relationships will be shown in startup logs.
# Value format: type, model ID, BaseURL, APIKey. API format must support OpenAI-compatible format. Type is currently unused
AI_MODEL_CONFIG_GEMINI_2_5_FLASH=fast,gemini-2.5-flash,https://api.example.com/v1,sk-abc
AI_MODEL_CONFIG_GEMINI_2_5_PRO=pro,gemini-2.5-pro,https://api.example.com/v1,sk-abc
# Install dependencies
pnpm i
# Develop CLI interface
pnpm run dev:cli
# Develop SSH Server
pnpm run dev
Special thanks to V.PS for sponsoring our servers.
Keep your files stored safely and securely with the SanDisk 2TB Extreme Portable SSD. With over 69,505 ratings and an impressive 4.6 out of 5 stars, this product has been purchased over 8K+ times in the past month. At only $129.99, this Amazon’s Choice product is a must-have for secure file storage.
Help keep private content private with the included password protection featuring 256-bit AES hardware encryption. Order now for just $129.99 on Amazon!
Help Power Techcratic’s Future – Scan To Support
If Techcratic’s content and insights have helped you, consider giving back by supporting the platform with crypto. Every contribution makes a difference, whether it’s for high-quality content, server maintenance, or future updates. Techcratic is constantly evolving, and your support helps drive that progress.
As a solo operator who wears all the hats, creating content, managing the tech, and running the site, your support allows me to stay focused on delivering valuable resources. Your support keeps everything running smoothly and enables me to continue creating the content you love. I’m deeply grateful for your support, it truly means the world to me! Thank you!
BITCOIN bc1qlszw7elx2qahjwvaryh0tkgg8y68enw30gpvge Scan the QR code with your crypto wallet app |
DOGECOIN D64GwvvYQxFXYyan3oQCrmWfidf6T3JpBA Scan the QR code with your crypto wallet app |
ETHEREUM 0xe9BC980DF3d985730dA827996B43E4A62CCBAA7a Scan the QR code with your crypto wallet app |
Please read the Privacy and Security Disclaimer on how Techcratic handles your support.
Disclaimer: As an Amazon Associate, Techcratic may earn from qualifying purchases.