Install Hermes Agent on VPS with Telegram Bot

curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash

Hermes first run after install, setup screen offering quick setup and full setup

Configure Model

Selecting a provider when setting the model; menu shows GitHub Copilot and More providers

Choosing a custom endpoint when selecting a provider, so you can enter your own CPA address

Enter your CPA's base url
Custom OpenAI-compatible endpoint filled with CPA base URL

Enter your CPA's api key
Terminal shows no input when filling in the CPA API key, which is normal

Under normal circumstances, the models supported by your CPA should be listed
After API verification passes, supported models are listed; pick a number with Select model
* If there are issues with your CPA, you can manually enter the model name
Manually enter model name when CPA has issues, example gpt-5.4

Context window size
Manually enter model gpt-5.4 and context window 128000

Set Up Message Channel

Choose Telegram or Discord as the message channel, or run hermes setup gateway later

Telegram as an example
Selecting Telegram as the message channel, typing 1 to confirm

Telegram channel checked, press Enter to continue

Telegram bot token
No prompt shown when entering the tg bot token, the red warning is normal

User ID of the Telegram account used to chat with the Telegram bot (your own Telegram account)
Query your numeric user ID from @userinfobot

Prompt asks whether to use this user ID as the Home Channel; press Enter to continue

Gateway

Configuring the Gateway, pressing Enter to confirm installing as a systemd service

For root user installation, you can choose System service
Choosing how to run the Gateway; root users select System service
* For non-root user installation, it is recommended to choose User service
Gateway run mode menu with User service selected

Shows the Gateway system service running as root

Shows Configured to run as: root, asks whether to start the service now

Complete

Install finishes with Ready to go, press Enter to start chatting over SSH

When you see the information above, the telegram bot is also ready to use.
Chat with the Hermes bot in Telegram, it answers who are you


========

Postscript

The VPS I use is a DediRock 2G RAM VPS 

Oracle VPS Ubuntu system, using a non-root user without sudo -i, the entire installation process can be completed using the official installation script.
Exiting the Hermes terminal shows Goodbye and returns to the ubuntu prompt


If the api key and tg bot token don't display, and you entered them incorrectly.
Then, after the installation process is complete, you can modify the configuration files yourself
~/.hermes/config.yaml
~/.hermes/.env

========

update

If you want to enable YOLO mode to skip all permission approvals
hermes config set approvals.mode off
If you want to disable terminal output masking information like bot_token api_key will be output to the terminal as-is which may leak into the context
hermes config set security.redact_secrets false
========

update

All along, Nous Portal officially provides a model for free use on a limited-time basis
For a while it was the Xiaomi mimo-v2 series, for a while it was step-3.5-flash, for a while it was qwen3.6-plus
Operation reference:

========

Want to see more


Comments