Dev Tools
Immich Photo Manager AI photo management for Immich, 94 tools, Immich 2.x and 3.x
Go-Docs MCP Install and Go: your AI reads any document

Gotify Commander

A remote control for your servers. The first Gotify plugin that talks back.

Gotify 3.1.1 · 2.9.1 Linux amd64 / arm64 / armv7 MIT License Open Source Gotify Plugin v0.5.0

The Problem

You’re on a walk. Your phone buzzes: a service needs a restart. With any other setup you’d need a laptop, a terminal and an SSH session. The walk is over.

The Solution

With gotify-commander you type restart nginx and get ✓ nginx restarted. It is the same app you already use for alerts, and now it answers. No laptop, no SSH, no terminal. The walk goes on.

▮▮
Commands & service management from your phone
▶
GPS location with reverse geocoding

Features

💻

27 Commands, 6 Categories

Restart services, check disks, read logs, analyze traffic, get a daily health summary, manage allow-listed Docker containers or locate your phone, all from the Gotify app you already use.

🌐

Web Control Panel

A console in the browser, protected by a password. A command line that suggests commands, machines and services while you type, the commands of your YAML categories one click away, and a session with every command that ran and its output.

🔄

Unified App Architecture

Commands and responses flow through a single Gotify app. Send a command, get the reply as the next notification. No separate channels to manage.

🖥

Multi-Machine

VPS services through systemctl, Mac services through SSH + launchctl. Set os: darwin on a Mac target and the diagnostics run what macOS has. Target any machine by name: free mac, uptime vps.

🔒

Security-First

Panel password generated by default, administrators only, and a command whitelist with no shell passthrough. Every command has a timeout, SSH host keys are checked, and messages are limited to 20 per minute. Reboot requires an explicit target.

📍

GPS Locate & Analytics

Locate your devices with locate. Analyze traffic with rhit, web analytics with GoAccess. TLS cert checks, DNS lookups, HTTP health probes.

⚙

Dynamic YAML Config

Add a service to the YAML and it appears in commands, the web UI and status reports. Categories, domains, ports, aliases and favicons all come from the config.

⭐

First Bidirectional Plugin

Every existing Gotify plugin is one-way, forwarding to Telegram, Slack or email. gotify-commander works both ways: type a command and the result comes back.

Architecture

gotify-commander loads as a native Gotify plugin (.so). It intercepts messages on a unified command app, executes the matching whitelisted command, and sends the result back as a notification on the same app.

# Data flow 📱 Phone → Gotify Client → Gotify Server → gotify-commander (.so) ↓ systemctl / SSH+launchctl → Target Machine ↓ Result notification → 📱 Phone # Web UI 💻 Browser → https://gotify.example.com/plugin/<id>/custom/<token>/ → Control Panel

The plugin runs inside the Gotify server process: no separate daemon, no extra ports, no external dependencies. Commands go to local systemctl, remote SSH/launchctl or diagnostic tools, as set in the YAML. The web UI is served at the plugin's webhook path.

Quick Start

Download the file for your Gotify version, copy it into the plugin directory and restart Gotify. Under two minutes.

Downloads

Pick the file of your Gotify version; gotify version tells you which one you run. Gotify 3.x needs the Android app 2.10.1 or newer. Earlier versions are on the releases page.

Install

  1. Download the file for your Gotify version and architecture, and check it against its .sha256.
  2. Copy it to the Gotify plugin directory: usually /opt/gotify/data/plugins/, or the plugins folder of your Docker data volume.
  3. Restart Gotify.
  4. In the Gotify WebUI, create a client (Clients → Create client) and copy its token now: Gotify 3 shows it only once.
  5. Open Plugins → gotify-commander, paste your YAML in Configure and enable the plugin.
  6. The plugin page now shows the control panel link and the generated panel password.
  7. Send help from the Gotify app on your phone.
# Example: Gotify 3.1.1 on amd64 sha256sum -c gotify-commander-linux-amd64-for-gotify-3.1.1.so.sha256 sudo cp gotify-commander-linux-amd64-for-gotify-3.1.1.so /opt/gotify/data/plugins/ sudo systemctl restart gotify

Command Reference

Help command output

27 commands in 6 categories. All of them accept aliases and machine targets.

🔄 Service Management (7)

Command Args Description
status[service]Status of all services, or a specific one
restart<service>Restart a service (supports aliases)
start<service>Start a service
stop<service>Stop a service
logs<service>Tail the last N lines of service logs
services—List all managed services
help—Show all commands and configured services

📊 System Diagnostics (9)

Command Args Description
free[vps|mac]Memory usage
df[vps|mac]Disk usage
uptime[vps|mac]System uptime + load average
top[vps|mac]Top processes by CPU/memory
who[vps|mac]Currently logged-in users
ping[vps|mac]Health check: responds with "pong" + latency
ip[vps|mac]IP addresses
ports[vps|mac]Open listening ports
connections[vps|mac]Socket statistics

🌐 Monitoring & Analytics (4)

Command Args Description
traffic[service]Nginx traffic analysis via rhit
analytics—Web analytics summary via GoAccess
certs—SSL certificate expiry for all domains
updates—Pending system updates (apt)

📍 Location (1)

Command Args Description
locate<lat> <lon>GPS reverse geocoding via OpenStreetMap

🧰 Operations (4)

Command Args Description
failed[vps|mac]Failed systemd units; on a macOS target it says it is not available
health—One summary: disks at 85% or more, load, memory, failed units and certificates that expire within 14 days
digest—The health summary now; with digest enabled it also arrives every day
dockerps [name] / restart <name> / logs <name>Only the containers in the allow-list; restart counts as dangerous

The four Operations commands are new in 0.4. docker acts only on the containers listed in docker.allowed_containers, and digest can arrive on its own every day at digest.at when digest.enabled is on.

⚠ Danger (2)

Command Args Description
reboot<vps|mac>Reboot a machine (requires explicit target)
shutdown<vps|mac>Shutdown a machine (requires explicit target)

Universal aliases: mem/memory → free · disk/space → df · log → logs · up → uptime. Typing just a service name is treated as status <service>.

Why Gotify Commander?

Every other Gotify plugin forwards notifications somewhere else. This one lets you act on them.

gotify-commander Telegram Bot Uptime Kuma
Self-hosted ✅ ❌ ✅
Bidirectional ✅ ✅ ❌
Runs inside Gotify ✅ ❌ ❌
No third-party services ✅ ❌ ✅
Service management ✅ varies ❌
Multi-machine (SSH) ✅ varies ❌
Web control panel ✅ ❌ ✅
Traffic & analytics ✅ ❌ ❌
GPS locate ✅ ❌ ❌
Tailscale security ✅ ❌ ❌
Phone app already installed ✅ ✅ ❌
The control panel: the command line, the commands and the session

Web Control Panel

A console for your machines in the browser, served by the plugin inside Gotify. The link is on the plugin page, next to the password.

  • A command line that suggests commands, machines, services and containers while you type: Tab completes, Enter runs, the up arrow recalls, / or Ctrl+K focuses it
  • The commands of your YAML categories beside the output on a wide screen and in tabs on a phone, with a service picker grouped by machine (favicon, description and port)
  • A session with every command, whether it worked, how long it took and its output, with buttons to copy it, run it again and remove it. The browser keeps it for 24 hours
  • Dangerous commands ask first in a dialog, with Cancel focused
  • Answers in Markdown are drawn as tables and links, and locate shows its map
  • Light and dark theme that follows the system, a page size from 50 % to 125 % and a padlock that forgets the password
Service suggestions while a command is typed
Suggestions while you type
The dialog that asks before a dangerous command
Confirmation of a dangerous command

The panel is protected by default. When no password is set, the plugin generates one and shows it only on the plugin page in Gotify; set web_password to use your own. The browser keeps it until you close the tab.

Configuration

All configuration lives in a single YAML file, editable in the Gotify WebUI. Define your services, categories, machines, domains and aliases. A service you add shows up everywhere.

# Example YAML configuration gotify: server_url: "http://localhost:2006" base_url: "https://gotify.example.com" client_token: "your-client-token" command_app_id: 1 web_password: "" # empty = generated, shown on the plugin page # enabled_commands: [ping, status, restart, logs, health] # require_confirm: [reboot, shutdown, stop] defaults: timeout: 30s rate_limit_per_minute: 20 replay_window: 5m categories: - label: "Machine" type: machine commands: [free, df, uptime, who, top, ports, ip, connections, updates, ping] - label: "Sites" type: service commands: [restart, stop, start, logs, traffic] - label: "Danger" type: machine danger: true commands: [reboot, shutdown] services: nginx: description: "🌐 Web Server" domain: "example.com" machine: vps port: 80 aliases: [ng, web] systemd: nginx homeserver: description: "🏠 Home Server" machine: mac port: 8080 aliases: [home] launchd: com.myapp.service ssh_targets: mac: host: "100.x.x.x" # Tailscale IP recommended port: 22 user: "admin" key_file: "/home/admin/.ssh/id_rsa" known_hosts_file: "/home/admin/.ssh/known_hosts" os: darwin # linux (default) or darwin for a Mac docker: allowed_containers: [myapp] digest: enabled: true at: "07:30"

Security

  • Panel password: the web control panel is protected by default. When no password is set, the plugin generates one and shows it only on the plugin page in Gotify. Set web_password to use your own.
  • Administrators only: only Gotify administrators get a working plugin instance. For other users the plugin page shows a notice and nothing starts.
  • Command whitelist: only the 27 registered commands run, with no arbitrary execution. List the ones you want in enabled_commands to allow fewer.
  • No shell: commands run through exec.Command without a shell, except two fixed scripts that get your input only as arguments. Service names must match ^[a-zA-Z0-9][a-zA-Z0-9._-]*$ and your configured list.
  • Timeouts: every command has a timeout (30 s by default) that kills its whole process group, so nothing is left running.
  • SSH host keys: SSH targets are checked against known_hosts, with no fallback to an unverified connection. Add the key as the user that runs Gotify: ssh-keyscan -p <port> <host> >> ~/.ssh/known_hosts.
  • Confirmation (optional): commands listed in require_confirm ask for a one-time code before they run when they arrive as a message.
  • Rate limit: 20 messages per minute per plugin instance. One over the limit does not run, and the reply says how long to wait.
  • Reboot requires a target: reboot alone returns an error, so a machine is never rebooted by accident.
  • SSH key only: password authentication is not supported.
  • Audit trail: every command is logged with timestamp, command, source, result and duration.
  • VPN: run Gotify behind Tailscale or WireGuard and do not expose it to the public internet.

When Gotify restarts

Commands posted while the plugin was offline, for example during a Gotify restart, run when it reconnects if they are younger than the replay window: replay_window, 5 minutes by default, and 0s turns it off.

Platform Compatibility

A Go plugin loads only when it was built with the same Go version and module versions as the Gotify server, so each release ships one file per Gotify version and architecture.

Platform Architecture Gotify
Linuxamd643.1.1 · 2.9.1
Linuxarm643.1.1 · 2.9.1
Linuxarm/v73.1.1 · 2.9.1

Built With

A single Go plugin (.so) with no runtime dependencies beyond Gotify itself.

  • Go Plugin (.so): loads natively inside the Gotify server
  • Gotify Plugin API: first-class integration, no hacks
  • SSH: remote machine management over standard SSH
  • YAML Config: human-readable, editable in the WebUI
  • Plain HTML, CSS and JavaScript: the control panel is one page with no framework, served under a strict Content Security Policy
  • Gin: lightweight HTTP router for the control panel
Gimme a coffee 😋
Buy Me A Coffee

I build tools I wish existed, then give them away.
If one of them saved you time, a coffee keeps the next one coming.

Buy Me A Coffee QR

Ready to manage your servers from your phone?

gotify-commander is free, open source, and ready to use with your Gotify instance.

7 Or gimme a star 🤗