Syntax
Commands
| Command | Description |
|---|---|
add | Add a new box configuration |
add-all | Add all boxes from Tailscale network |
delete | Delete a box configuration |
edit | Edit an existing box configuration |
list | List all configured boxes |
delete-all | Delete all box configurations |
export | Export box configuration to JSON |
import | Import box configuration from JSON |
sync | Sync Lager Box versions from all boxes |
Command Reference
add
Add a new Lagerbox configuration.
--name(required) - Name to assign to the box--ip(required) - IP address of the box--user- SSH username (default: lagerdata)--version- Lager Box version/branch (e.g., staging, main)--yes- Confirm without prompting
add-all
Automatically add all Lagerboxes found on your Tailscale network.
--yes- Confirm without prompting
- Runs
tailscale statusto discover devices - Filters for devices with names 5-8 characters long
- Converts names to uppercase
- Skips boxes that already exist with the same IP
- Adds new boxes to your configuration
delete
Delete a box configuration.
edit
Edit an existing box configuration.
--name(required) - Name of the box to edit--ip- New IP address--user- New SSH username--version- New Lager Box version/branch--new-name- Rename the box--yes- Confirm without prompting
list
List all configured boxes.
delete-all
Delete all box configurations.
export
Export box configuration to JSON file.
--output/-o- Output file path (prints to stdout if not specified)
import
Import box configuration from JSON file.
FILE- Path to JSON file to import--merge- Merge with existing boxes (default: replace)--yes- Confirm without prompting
sync
Sync Lager Box versions from all configured boxes.
--port- Lager Box HTTP port (default: 5000)--timeout- HTTP request timeout in seconds (default: 5)
Configuration Storage
Box configurations are stored in.lager file in your project directory:
- Simple: Just an IP address string
- Full: Object with ip, user, and version fields
Validation
The boxes commands perform validation:- Duplicate detection: Prevents adding boxes with same name or IP
- IP validation: Validates IP address format
- Confirmation: Shows before/after state for edit operations
Examples
Notes
- Box names must be unique
- IP addresses must be unique (no duplicate IPs)
- The default SSH user is
lagerdata - Use
--mergewhen importing to preserve existing boxes - Sync command requires Lager Boxes to be online and accessible

