What the service is
Alter is one background process. The alter command, the app, the browser UI, Slack, Telegram and Discord all talk to it. Routines and watches also run inside it, so they only run while it is running. alter service starts it at login and restarts it if it fails.
sh
alter service install
alter service statusalter service install --print shows what would be installed without installing it. alter service uninstall removes it.
How it is installed
| Situation | What alter service install uses |
|---|---|
| macOS | A LaunchAgent in your user account, with the label io.nubisco.alter. |
| Linux | A systemd user unit, with the label io.nubisco.alter. |
| Installed with Homebrew | brew services. If an older login item of Alter's own is present, it is replaced. |
None of these needs root. The install script refuses to run as root.
You can also set this up during alter setup, which offers to start Alter at login.
The desktop app
On a Mac, the app keeps Alter running in the menu bar. Closing the window does not stop Alter. If the background service is installed, the app is simply another client of it.
Running on a Linux server
The Linux build has the CLI, the daemon and the browser UI. There is no Linux desktop app. The UI only listens on 127.0.0.1, so to use it from your own computer you reach it through an SSH tunnel.
On the server:
sh
curl -fsSL https://downloads.nubisco.io/alter/install.sh | sh
alter setup
alter service installThen ask Alter how to reach the UI:
sh
alter ui --remoteIt prints the exact commands for your server. The idea is to forward a port on your computer to the server's loopback port (7420 unless you set ALTER_UI_PORT), and then open the sign-in link it printed:
sh
ssh -L 7420:127.0.0.1:7420 you@your-serverThe sign-in link is a one-time link and is valid for about two minutes. Run alter ui --no-open on the server to get a fresh one.
Slack, Telegram and Discord need no inbound ports, because Alter connects outward to all three. See Slack.
Keychain on Linux
On Linux, Alter stores secrets through the Secret Service, using the secret-tool command. The machine therefore needs a running Secret Service provider (such as GNOME Keyring or KeePassXC) and secret-tool installed. On a headless server you have to provide one before you can connect a model or a channel, because Alter keeps secrets only in the keychain and never in its settings file. On macOS it uses the login Keychain.
Updates
alter update updates the app, the CLI and the Homebrew install together. A service started by Homebrew is managed by Homebrew, so use alter update or brew upgrade as you installed it. See CLI reference.
Logs and troubleshooting
The service writes alter.log in the data folder. If Alter stops, alter service status tells you whether the service is running. If it crashed, the scrubbed crash report is in objects/crashes/ and alter bug --crash opens the report form with it.