Quick Start
Create your first automated backup in under 5 minutes.
This guide walks you through setting up OpsVault from a fresh binary to a running scheduled backup.
Don't have OpsVault installed yet? Run the one-line installer first:
curl -fsSL https://get.opsvault.dev | sudo bashThe installer handles the binary, optional dependencies, and the service. Come back here to configure your first backup.
Create the config file
opsvault config initThis writes a fully commented template to /etc/opsvault/config.yaml.
Configure your databases
The easiest way is the interactive wizard — no YAML editing required:
opsvault config wizardUse ↑ ↓ to navigate, Enter to select. Go to Databases → Add new database, fill in your host, user, database name, and password env var, then Save & Exit.
Prefer editing by hand? Open the file directly:
nano /etc/opsvault/config.yamlAt minimum, add a database block:
databases:
- name: myapp
type: postgres # or: mysql
host: 127.0.0.1
port: 5432
user: backup_user
password_env: DB_PASS
database: myapp_prod
enabled: trueSet the password via environment variable so it is never stored in plain text:
echo 'export DB_PASS=yourpassword' >> /etc/environment
source /etc/environmentValidate the config
opsvault config validateIf there are errors, they will be listed clearly. Fix them before continuing.
Run a manual backup
opsvault backup runA successful run looks like:
✓ myapp (1.2s)
/var/backups/opsvault/myapp_20240115_020000.sql.gzList your backups:
opsvault backup listInstall as a systemd service
opsvault service install
systemctl start opsvault
systemctl status opsvaultOpsVault will now run automatically on every server boot and back up your databases on the configured schedule (default: every night at 02:00).