Install Alpamon

Learn how to install the Alpacon agent (Alpamon) on your servers and connect them to your workspace.

Prerequisites

Before installing Alpacon, ensure you have:

  • Alpacon workspace: Book a demo and we set one up with you, or ask your admin for an invitation
  • Server requirements:
    • Supported OS (see supported platforms)
    • Root or sudo access for installation
    • Outbound HTTPS connectivity (port 443)
    • 150MB free disk space
    • 128MB available RAM

Supported platforms

See Supported platforms for operating systems and architectures.

Feature scope per platform

See the Windows feature matrix for features that differ by platform.

Quick installation

The recommended way to install and register Alpamon:

Step 1: Prepare server registration in workspace

  1. Log in to your Alpacon workspace
  2. Go to Servers → Register server and choose Registration with token
  3. Under What is the server’s OS?, select the platform, optionally set a Server name, and pick a registration token. Access groups are inherited from the token, not set on this form.

See Register a server for the full registration flow (including Ansible).

Step 2: Install using the generated command

Copy the command your workspace generates and run it on the server. The workspace tailors it to the platform you selected.

Linux / macOS—paste into a terminal:

bash
# The command will look similar to this:
curl https://your-workspace.us1.alpacon.io/api/servers/installers/YOUR_UNIQUE_ID/ | sudo -EH bash

Windows—paste into an elevated PowerShell (Run as Administrator). The generated command downloads the agent from GitHub Releases, verifies its checksum, and runs alpamon.exe register. See Windows for the equivalent manual steps.

In either case, the command will:

  1. Install the Alpamon agent
  2. Register the server with your workspace
  3. Start the agent as a service
Note

On Linux and macOS, sudo -EH preserves your environment variables (such as proxy settings) and sets HOME for the install.

Step 3: Verify installation

In your workspace, verify the server shows as Online in the server list. You can now access it via terminal.

Manual installation (advanced)

Note

For most users, we recommend using the workspace-generated install command (see Quick installation). Manual installation requires separate registration.

Linux packages are hosted on packagecloud.io. macOS uses a Homebrew tap. Windows uses release archives published on GitHub Releases.

Linux

This method allows automatic updates through your system’s package manager.

Step 1: Get environment variables from Alpacon

Before installation, you need to obtain registration credentials from your Alpacon workspace.

Option A: Via Alpacon Web UI

  1. Log in to your Alpacon workspace
  2. Navigate to Servers → Register server
  3. Create a new server entry
  4. Copy the environment variables from the installation instructions: ALPACON_URL, PLUGIN_ID, PLUGIN_KEY

Option B: Via Alpacon CLI

bash
# Create server via CLI (interactive prompts)
alpacon server create
 
# After creation, you'll see installation instructions including environment variables
# Copy the ALPACON_URL, PLUGIN_ID, and PLUGIN_KEY values
Step 2: Set environment variables

Export the credentials on your target server:

bash
export ALPACON_URL="https://your-workspace.us1.alpacon.io"
export PLUGIN_ID="your-plugin-id"
export PLUGIN_KEY="your-plugin-key"
Important

Use export to ensure these variables are available during installation. The -EH flags in sudo -EH preserve your environment variables and set HOME for the install.

Step 3: Install Alpamon

DEB-based systems (Ubuntu/Debian):

bash
# Add repository and GPG key (preserves environment variables)
curl -s https://packagecloud.io/install/repositories/alpacax/alpamon/script.deb.sh?any=true | sudo -EH bash
 
# Install Alpamon (uses environment variables for auto-registration)
sudo -EH apt-get install -y alpamon
 
# Start and enable the service
sudo systemctl start alpamon
sudo systemctl enable alpamon

RPM-based systems (RHEL/Rocky/Alma/Fedora):

bash
# Add repository (preserves environment variables)
curl -s https://packagecloud.io/install/repositories/alpacax/alpamon/script.rpm.sh?any=true | sudo -EH bash
 
# Install Alpamon (uses environment variables for auto-registration)
sudo -EH yum install -y alpamon
 
# Start and enable the service
sudo systemctl start alpamon
sudo systemctl enable alpamon

SUSE-based systems (openSUSE/SLES):

bash
# Add the repository to zypper (skipped when an alpamon repository already exists)
sudo -EH zypper lr alpamon >/dev/null 2>&1 || \
  sudo -EH zypper --non-interactive addrepo -f \
  'https://packagecloud.io/alpacax/alpamon/rpm_any/rpm_any/$basearch' alpamon
sudo -EH zypper --non-interactive --gpg-auto-import-keys refresh alpamon
 
# Install Alpamon (uses environment variables for auto-registration)
sudo -EH zypper --non-interactive install alpamon
 
# Start and enable the service
sudo systemctl start alpamon
sudo systemctl enable alpamon

Don’t use the RPM-based script.rpm.sh command on openSUSE or SLES: it sets up a repository that zypper can’t use.

Note

If your workspace has sudo with MFA enabled, also install the PAM module by adding alpamon-pam to the install command—for example sudo -EH apt-get install -y alpamon alpamon-pam (or yum on RHEL-based systems and zypper on openSUSE/SLES). openSUSE and SLES need alpamon-pam 1.1.5 or later (see PAM and sudo issues). The workspace-generated command adds this automatically.

Method 2: Direct package download

Download and install a specific package version directly. This method also requires environment variables for auto-registration.

Step 1: Get and set environment variables

Follow the same steps as Method 1 to obtain and export ALPACON_URL, PLUGIN_ID, and PLUGIN_KEY.

bash
export ALPACON_URL="https://your-workspace.us1.alpacon.io"
export PLUGIN_ID="your-plugin-id"
export PLUGIN_KEY="your-plugin-key"
Step 2: Download and install

DEB-based systems (Ubuntu/Debian):

bash
# Download the package. Filenames follow alpamon_<version>_linux_<arch>.deb —
# check the exact filename on the package page: https://packagecloud.io/alpacax/alpamon
wget "https://packagecloud.io/alpacax/alpamon/packages/ubuntu/focal/alpamon_<version>_linux_amd64.deb/download.deb" -O alpamon.deb
 
# Install the package (preserves environment variables)
sudo -EH dpkg -i alpamon.deb
 
# Install any missing dependencies
sudo -EH apt-get install -f -y
 
# Start the service
sudo systemctl start alpamon
sudo systemctl enable alpamon

RPM-based systems (RHEL/Rocky/Alma/Fedora):

bash
# Download the package. Filenames follow alpamon-<version>-1.linux.<arch>.rpm —
# check the exact filename on the package page: https://packagecloud.io/alpacax/alpamon
wget "https://packagecloud.io/alpacax/alpamon/packages/el/8/alpamon-<version>-1.linux.x86_64.rpm/download.rpm" -O alpamon.rpm
 
# Install the package (preserves environment variables)
sudo -EH rpm -i alpamon.rpm
 
# Start the service
sudo systemctl start alpamon
sudo systemctl enable alpamon

Browse all packages: Visit packagecloud.io/alpacax/alpamon to view all available packages for different OS versions and architectures.

Note

If environment variables are set correctly during installation, the agent will auto-register. Otherwise, proceed to manual registration.

macOS

Install Alpamon with Homebrew, then run alpamon register to write the config and start the launchd service. The $(brew --prefix) form below works on both Apple Silicon (/opt/homebrew/bin) and Intel (/usr/local/bin) Macs. Use the full path because sudo may not find Homebrew-installed binaries on Apple Silicon.

bash
brew tap alpacax/alpacon
brew install alpamon
sudo "$(brew --prefix)/bin/alpamon" register \
  --url https://your-workspace.us1.alpacon.io \
  --token YOUR_REGISTRATION_TOKEN

brew install is safe to re-run, but alpamon register itself fails on a host that is already registered—it reports config file already exists. To re-register or recover, run alpamon register --force (or alpamon unregister then alpamon register) on the server itself. See registration recovery.

Windows

Open an elevated PowerShell (Run as Administrator) and choose one of the methods below. In both cases, alpamon.exe register installs the agent under C:\Program Files\alpamon\, registers it as a Windows service that starts automatically on boot, and starts the service. The install.ps1 script is safe to re-run, but alpamon.exe register itself fails on a host that is already registered (config file already exists). To re-register or recover, run alpamon.exe register --force (or alpamon.exe unregister then alpamon.exe register) from the server, not over Websh. See registration recovery.

Method 1: Manual install

  1. Download alpamon-X.Y.Z-windows-amd64.zip from GitHub Releases. The binary is not signed, so Windows may block it (SmartScreen). Unblock the ZIP before extracting: Unblock-File .\alpamon-X.Y.Z-windows-amd64.zip. Then extract the archive.
  2. From an elevated PowerShell in the extracted folder:
powershell
.\alpamon.exe register `
    --url https://your-workspace.us1.alpacon.io `
    --token YOUR_REGISTRATION_TOKEN

Method 2: Automated install with install.ps1

Recommended for cloud-init, EC2 UserData, Packer, and Azure Custom Script Extension. The script downloads the release archive, verifies the download integrity using the checksums published with the release, extracts it, and runs alpamon register.

Download-then-run (preferred—keeps the installer on disk for audit):

powershell
$env:ALPAMON_URL   = "https://your-workspace.us1.alpacon.io"
$env:ALPAMON_TOKEN = "YOUR_REGISTRATION_TOKEN"
$installer = Join-Path $env:TEMP 'alpamon-install.ps1'
Invoke-WebRequest -UseBasicParsing `
    -Uri 'https://raw.githubusercontent.com/alpacax/alpamon/main/scripts/install.ps1' `
    -OutFile $installer
& powershell -ExecutionPolicy Bypass -File $installer

Pipe-to-iex (terse, trades auditability for brevity):

powershell
$env:ALPAMON_URL   = "https://your-workspace.us1.alpacon.io"
$env:ALPAMON_TOKEN = "YOUR_REGISTRATION_TOKEN"
iwr https://raw.githubusercontent.com/alpacax/alpamon/main/scripts/install.ps1 -UseB | iex

Advanced: manual registration

If you installed Alpamon manually (without the workspace-generated install command), you can register it separately:

Get registration information

  1. Log in to your Alpacon workspace
  2. Go to Servers → Register server and choose Registration with token
  3. In the Server registration token field, click Create new token and copy the key it shows. The key is shown only once, so to reuse an existing server registration token, use the key you saved when you created it.

Register the server

Run the registration command on your server:

bash
sudo alpamon register \
  --url https://your-workspace.us1.alpacon.io \
  --token YOUR_REGISTRATION_TOKEN \
  --name "production-web-01" \
  --tag env=prod --tag role=web

Options:

  • --url: Alpacon server URL (required)
  • --token: Server registration token key (required)
  • --name: Server name (optional, defaults to hostname)
  • --platform: Platform type—debian, rhel, darwin, or windows (optional, auto-detected)
  • --ssl-verify: Enable SSL certificate verification (default: true)
  • --ca-cert: CA certificate file path (optional)
  • --tag: Server tag in key=value format (optional, repeatable)
  • --no-cloud-probe: Skip cloud provider metadata auto-detection on cloud hosts (optional)
  • --force: Recover a stuck server. Registers anew, then retires the previous registration once the new one is committed (the old registration is kept until the new one succeeds). Requires alpamon v2.3.0 or later.
  • --no-rollback: Leave partial state in place if registration fails instead of cleaning it up (debugging only, not for normal use). Requires alpamon v2.3.0 or later.

Verify registration

Check the agent status using the command for your platform.

Linux

bash
sudo systemctl status alpamon
sudo journalctl -u alpamon -f

macOS

bash
sudo launchctl print system/com.alpacax.alpamon
tail -f /var/log/alpamon/alpamon.log

Windows

powershell
sc.exe query alpamon
Get-Content "$env:ProgramData\alpamon\log\alpamon.log" -Wait -Tail 50

In your workspace:

  1. Go to Servers page
  2. Your server should appear as “Connected”
  3. Click on the server to access terminal

Next steps

After successful installation:

  1. Configure access controls - Set up roles and permissions
  2. Connect via Websh - Access your server through the browser
  3. Review activity - Audit sessions, commands, and approval decisions
  4. Integrate with CI/CD - Automate deployments

Need help?

Last updated: