Environment Variables

rtmn reads RTMN_* environment variables from the systemd EnvironmentFile.

Variable List

VariableRequiredDefaultDescription
RTMN_TELEGRAM_TOKENYesNoneTelegram bot token
RTMN_ALLOWED_CHAT_IDSYesNoneAllowed chat ID list
RTMN_SHELL_PATHNo/bin/bashShell to execute
RTMN_SHELL_ARGSNoEmptyShell arguments
RTMN_AUDIT_LOG_PATHNo/var/log/rtmn/audit.logAudit log path
RTMN_AUDIT_MAX_BYTESNo10485760Audit log rotation size
RTMN_AUDIT_MAX_BACKUPSNo5Number of audit log backups
RTMN_DEBOUNCE_MSNo200Output debounce time
RTMN_MAX_CHUNK_SIZENo3500Telegram output chunk size
RTMN_POLL_TIMEOUT_SECNo30Telegram polling timeout
RTMN_INCOMING_RATE_PER_MINNo30Per-chat input rate limit
RTMN_OUTGOING_RATE_PER_SECNo25Global output rate limit
RTMN_OUTPUT_OVERFLOW_BYTESNo262144Output flood cutoff threshold
RTMN_BLOCKED_INTERACTIVENoBuilt-in denylistInteractive program denylist

Single-Instance Environment File

The default installer creates this environment file:

/etc/rtmn/env

Recommended permissions:

owner: root
group: root
mode:  0600

Account-Isolated Environment Files

Account-isolated installations use one environment file per instance.

Examples:

/etc/rtmn/env-ops
/etc/rtmn/env-app
/etc/rtmn/env-admin

Interactive Program Denylist

If RTMN_BLOCKED_INTERACTIVE is set, it replaces the built-in denylist.

To add entries while keeping defaults, list the default entries and additions together.

Example:

RTMN_BLOCKED_INTERACTIVE=nano,vim,vi,top,htop,mysql,psql,python3

Was this page helpful?

Last update